所属部门自动搜索
This commit is contained in:
parent
bd036feee2
commit
44da94a71e
|
@ -126,7 +126,13 @@
|
||||||
title="已申请摄像头列表"
|
title="已申请摄像头列表"
|
||||||
@ok="videoVisible = false"
|
@ok="videoVisible = false"
|
||||||
>
|
>
|
||||||
<a-select placeholder="请选择归属部门" v-model:value="deptName" :getPopupContainer="(triggerNode) => triggerNode.parentNode" show-search option-filter-prop="children" :filterOption="filterOption" @change="deptIdChangeFunction">
|
<a-select placeholder="请选择归属部门"
|
||||||
|
style="width: 200px"
|
||||||
|
v-model:value="deptName"
|
||||||
|
:getPopupContainer="(triggerNode) => triggerNode.parentNode"
|
||||||
|
show-search
|
||||||
|
:filterOption="true"
|
||||||
|
@change="deptIdChangeFunction">
|
||||||
<a-select-option v-for="(item, index) in deptNameAll" :key="`${index}-${item}`" :value="item.name">
|
<a-select-option v-for="(item, index) in deptNameAll" :key="`${index}-${item}`" :value="item.name">
|
||||||
{{ item.name }}
|
{{ item.name }}
|
||||||
</a-select-option>
|
</a-select-option>
|
||||||
|
@ -204,6 +210,7 @@
|
||||||
const showItem = (id, type, delFlag, note1) => {
|
const showItem = (id, type, delFlag, note1) => {
|
||||||
if (type == '基础设施') {
|
if (type == '基础设施') {
|
||||||
let arr = JSON.parse(note1);
|
let arr = JSON.parse(note1);
|
||||||
|
//console.log('arrarr====',arr);
|
||||||
xVideoList.value = []
|
xVideoList.value = []
|
||||||
arr.map((val) => {
|
arr.map((val) => {
|
||||||
xVideoList.value.push({
|
xVideoList.value.push({
|
||||||
|
@ -244,10 +251,6 @@
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
getDeptAllData();
|
getDeptAllData();
|
||||||
//select搜索过滤
|
|
||||||
const filterOption = (input, option) => {
|
|
||||||
return option.value.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="less">
|
<style scoped lang="less">
|
||||||
|
|
|
@ -88,6 +88,9 @@
|
||||||
v-else
|
v-else
|
||||||
placeholder="请选择归属部门"
|
placeholder="请选择归属部门"
|
||||||
v-model:value="formName.unit"
|
v-model:value="formName.unit"
|
||||||
|
:getPopupContainer="(triggerNode) => triggerNode.parentNode"
|
||||||
|
show-search
|
||||||
|
:filterOption="true"
|
||||||
@change="deptIdChangeFunction"
|
@change="deptIdChangeFunction"
|
||||||
>
|
>
|
||||||
<a-select-option
|
<a-select-option
|
||||||
|
|
Loading…
Reference in New Issue