对接项目详情的法规清单

This commit is contained in:
qq787203167
2022-04-18 16:35:34 +08:00
parent 8946082303
commit 4e6ee68d7e
4 changed files with 48 additions and 16 deletions
@@ -23,7 +23,8 @@
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-input-search style="margin-bottom: 8px" placeholder="Search" @change="onChange"/>
<a-input-search style="margin-bottom: 8px":placeholder="$t('NodeQuickLookup')"
v-model="searchModel" @search="onSearch"/>
<div class="drawer-content">
<a-tree
style="margin-bottom: 60px;height: 600px"
@@ -66,6 +67,7 @@
departId: '',
selectedKey: [],
userIds: [],
searchModel:'',
defaultExpandedKeys: [],
defaultCheckedKeys: []
}
@@ -77,6 +79,7 @@
standardClick() {
this.treeVisible = false
this.departId = ''
this.searchModel = ''
this.userIds = []
this.userName = []
this.queryDepartUserTreeList()
@@ -91,7 +94,7 @@
this.userName = []
if (info.checkedNodes && info.checkedNodes.length > 0) {
info.checkedNodes.forEach(res => {
this.userIds.push(res.data.props.id)
this.userIds.push(res.data.props.id || res.data.props.dataRef.key)
this.userName.push(res.data.props.title)
})
}
@@ -120,15 +123,30 @@
indexclick(event) {
this.$emit('input', event.target.value)
},
onChange() {
onSearch(e) {
this.gData = []
this.departId = ''
this.visibleTree = false
if (e) {
this.getUserAndDepart()
} else {
this.queryDepartUserTreeList()
}
},
getUserAndDepart() {
getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => {
this.gData = res || []
this.visibleTree = true
})
},
onExpand(selectedKeys, val) {
if (val.expanded) {
if (this.departId == val.node.value) {
} else {
this.departId = val.node.value
this.queryDepartUserTreeList()
if (this.searchModel == '' || !this.searchModel) {
if (val.expanded) {
if (this.departId == val.node.value) {
} else {
this.departId = val.node.value
this.queryDepartUserTreeList()
}
}
}
},