|
@ -107,27 +107,6 @@ export default { |
|
|
handleSelectionChange(e) { |
|
|
handleSelectionChange(e) { |
|
|
this.tableCheckData = e || []; |
|
|
this.tableCheckData = e || []; |
|
|
}, |
|
|
}, |
|
|
// 获取行政区数据 |
|
|
|
|
|
getTreeData() { |
|
|
|
|
|
getAreasData().then((items) => { |
|
|
|
|
|
let res = []; |
|
|
|
|
|
let getChildren = (res, pid) => { |
|
|
|
|
|
for (const i of items.data) { |
|
|
|
|
|
if (i.parentid === pid) { |
|
|
|
|
|
const newItem = { |
|
|
|
|
|
label: i.name, |
|
|
|
|
|
value: i.id, |
|
|
|
|
|
}; |
|
|
|
|
|
if (i.layer != 3) newItem.children = []; |
|
|
|
|
|
res.push(newItem); |
|
|
|
|
|
getChildren(newItem.children, newItem.value); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}; |
|
|
|
|
|
getChildren(res, items.data[0].parentid); |
|
|
|
|
|
this.areasOptions = res; |
|
|
|
|
|
}); |
|
|
|
|
|
}, |
|
|
|
|
|
// 批量删除 |
|
|
// 批量删除 |
|
|
handleDelAll() { |
|
|
handleDelAll() { |
|
|
if (this.tableCheckData.length === 0) { |
|
|
if (this.tableCheckData.length === 0) { |
|
@ -279,7 +258,6 @@ export default { |
|
|
}, |
|
|
}, |
|
|
}, |
|
|
}, |
|
|
created() { |
|
|
created() { |
|
|
this.getTreeData(); |
|
|
|
|
|
// 获取状态字典 |
|
|
// 获取状态字典 |
|
|
getDicts("xs_yh_record_status").then((res) => { |
|
|
getDicts("xs_yh_record_status").then((res) => { |
|
|
if (res.data && Array.isArray(res.data)) { |
|
|
if (res.data && Array.isArray(res.data)) { |
|
@ -313,7 +291,6 @@ export default { |
|
|
<div class="search-item flex items-center"> |
|
|
<div class="search-item flex items-center"> |
|
|
<span class="search-label">行政区划</span> |
|
|
<span class="search-label">行政区划</span> |
|
|
<el-cascader |
|
|
<el-cascader |
|
|
:options="areasOptions" |
|
|
|
|
|
v-model="paramsData.adcd" |
|
|
v-model="paramsData.adcd" |
|
|
:props="areasOptionProps" |
|
|
:props="areasOptionProps" |
|
|
placeholder="请选择行政区划" |
|
|
placeholder="请选择行政区划" |
|
|