|
@@ -132,7 +132,7 @@
|
|
<!-- 添加编辑 -->
|
|
<!-- 添加编辑 -->
|
|
<template>
|
|
<template>
|
|
<template slot="householdType">
|
|
<template slot="householdType">
|
|
- <el-select v-model="item.householdType" clearable>
|
|
|
|
|
|
+ <el-select v-model="item.householdType" clearable @change="householdTypeHide(item)">
|
|
<el-option
|
|
<el-option
|
|
v-for="(item, index) in householdTypeArray"
|
|
v-for="(item, index) in householdTypeArray"
|
|
:key="index"
|
|
:key="index"
|
|
@@ -495,7 +495,7 @@ export default {
|
|
height: '400px',
|
|
height: '400px',
|
|
props: {
|
|
props: {
|
|
num: 1,
|
|
num: 1,
|
|
- list: this.formData.houseList,
|
|
|
|
|
|
+ list: this.formData.houseList || [],
|
|
tenantsTree: this.communityArr,
|
|
tenantsTree: this.communityArr,
|
|
callback: resolve
|
|
callback: resolve
|
|
},
|
|
},
|
|
@@ -525,6 +525,10 @@ export default {
|
|
});
|
|
});
|
|
},
|
|
},
|
|
addCard(itemObj) {
|
|
addCard(itemObj) {
|
|
|
|
+ if (itemObj.householdType !== 1) {
|
|
|
|
+ this.$message.error('只能业主才能绑定车位');
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
new Promise((resolve) => {
|
|
new Promise((resolve) => {
|
|
this.$store.dispatch('addPopup', {
|
|
this.$store.dispatch('addPopup', {
|
|
url: '/ownerManagement/stepPage/poptreeSelect.vue',
|
|
url: '/ownerManagement/stepPage/poptreeSelect.vue',
|
|
@@ -532,7 +536,7 @@ export default {
|
|
height: '400px',
|
|
height: '400px',
|
|
props: {
|
|
props: {
|
|
num: 2,
|
|
num: 2,
|
|
- list: itemObj.parkingList,
|
|
|
|
|
|
+ list: itemObj.parkingList || [],
|
|
tenantsTree: this.garageArr,
|
|
tenantsTree: this.garageArr,
|
|
callback: resolve
|
|
callback: resolve
|
|
},
|
|
},
|
|
@@ -617,11 +621,22 @@ export default {
|
|
if (!!item.children & (item.type !== 'unit')) {
|
|
if (!!item.children & (item.type !== 'unit')) {
|
|
this.dimension(item.children);
|
|
this.dimension(item.children);
|
|
} else {
|
|
} else {
|
|
- if (item.name.indexOf('单元') === -1 && item.type === 'unit') {
|
|
|
|
- item.name = item.name + '单元';
|
|
|
|
- }
|
|
|
|
|
|
+ item.name = this.CheckChinese(item.name, type == 'unit' ? '单元' : '楼栋');
|
|
}
|
|
}
|
|
});
|
|
});
|
|
|
|
+ },
|
|
|
|
+ CheckChinese(val, name) {
|
|
|
|
+ var reg = new RegExp('[\\u4E00-\\u9FFF]+', 'g');
|
|
|
|
+ let newVal = val;
|
|
|
|
+ if (!reg.test(val)) {
|
|
|
|
+ newVal = val + name;
|
|
|
|
+ }
|
|
|
|
+ return newVal;
|
|
|
|
+ },
|
|
|
|
+ householdTypeHide(item) {
|
|
|
|
+ if (item.householdType !== 1) {
|
|
|
|
+ item.parkingList = [];
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
};
|