|
|
@@ -44,10 +44,17 @@
|
|
|
height: '40px',
|
|
|
}"
|
|
|
class="item-label"
|
|
|
- >变电站</label
|
|
|
+ >归属县旗</label
|
|
|
>
|
|
|
- <el-select style="width: 100%" v-model="searchForm.subId" placeholder="变电站" @keydown.enter.native="search()" clearable>
|
|
|
- <el-option v-for="item in subList" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
+ <el-select
|
|
|
+ style="width: 100%"
|
|
|
+ v-model="searchForm.compId"
|
|
|
+ placeholder="归属县旗"
|
|
|
+ @keydown.enter.native="search()"
|
|
|
+ @change="getSubList"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option v-for="item in compList" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
</el-select>
|
|
|
</div>
|
|
|
<div
|
|
|
@@ -69,12 +76,13 @@
|
|
|
height: '40px',
|
|
|
}"
|
|
|
class="item-label"
|
|
|
- >归属县旗</label
|
|
|
+ >变电站</label
|
|
|
>
|
|
|
- <el-select style="width: 100%" v-model="searchForm.compId" placeholder="归属县旗" @keydown.enter.native="search()" clearable>
|
|
|
- <el-option v-for="item in compList" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
+ <el-select style="width: 100%" v-model="searchForm.subId" placeholder="变电站" @keydown.enter.native="search()" clearable>
|
|
|
+ <el-option v-for="item in subList" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
</el-select>
|
|
|
</div>
|
|
|
+
|
|
|
<div :style="{ alignItems: 'center', margin: '0 10px 0 0', display: 'flex' }">
|
|
|
<label
|
|
|
:style="{
|
|
|
@@ -606,7 +614,7 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
|
- this.getSubList();
|
|
|
+ // this.getSubList();
|
|
|
this.getCompList();
|
|
|
this.getDataList();
|
|
|
},
|
|
|
@@ -655,6 +663,7 @@ export default {
|
|
|
limit: this.pageSize,
|
|
|
sort: 'id',
|
|
|
order: 'desc',
|
|
|
+ compId: this.searchForm.compId,
|
|
|
};
|
|
|
const { data } = await this.$http({
|
|
|
url: '/sub/page',
|
|
|
@@ -666,6 +675,7 @@ export default {
|
|
|
label: item.subName,
|
|
|
value: String(item.id),
|
|
|
}));
|
|
|
+ this.searchForm.subId = undefined;
|
|
|
}
|
|
|
},
|
|
|
// 获取公司列表
|