|
@@ -42,6 +42,7 @@
|
|
|
:key="index"
|
|
|
:label="item.name"
|
|
|
:value="item.id"
|
|
|
+ @click.native="formDataStrategyId(index)"
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
|
|
@@ -114,7 +115,7 @@ export default {
|
|
|
selectData: [],
|
|
|
dateLandlady: [],
|
|
|
dateBuilding: [],
|
|
|
- strategyId: '',
|
|
|
+ strategyId: [],
|
|
|
formRules: {
|
|
|
residentId: [this.$valid.selectRequired('房东')],
|
|
|
assetsId: [this.$valid.selectRequired('楼栋')],
|
|
@@ -125,6 +126,13 @@ export default {
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
+
|
|
|
+ formDataStrategyId (id) {
|
|
|
+
|
|
|
+ this.formData.strategyId = this.strategyId[id];
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
submit () {
|
|
|
this.$refs.form.validate((valid) => {
|
|
|
if (valid) {
|
|
@@ -199,13 +207,15 @@ export default {
|
|
|
this.$http.get('/czc-community/landlord/buildingList', { id: this.formData.residentId }).then(({ data, status, msg }) => {
|
|
|
if (status == 0) {
|
|
|
this.dateBuilding = [];
|
|
|
+ this.strategyId = [];
|
|
|
for (let i = 0; i < data.length; i++) {
|
|
|
this.dateBuilding.push({
|
|
|
name: data[i].communityName + '-' + data[i].buildingName,
|
|
|
id: data[i].id + '-' + data[i].strategyId
|
|
|
})
|
|
|
- this.strategyId = data[i].strategyId;
|
|
|
- this.formData.strategyId = data[i].strategyId;
|
|
|
+
|
|
|
+ this.strategyId.push(data[i].strategyId)
|
|
|
+
|
|
|
this.scChargeStrategy(i);
|
|
|
}
|
|
|
}
|