Commit 577970a9 authored by wangdanlei's avatar wangdanlei

6509 表单配置选择任意类型必填控制台报错 6462 列表字典选择项过滤无数据 6555 【通飞MES】表格行内对齐方式不生效/【 通飞MES】通用选人组件多选不生效根据组织过滤不生效

parent f6d071e8
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -21,13 +21,6 @@ export default {
// name: 'el-switch'
// }
// },
{
key: 'isFilterByOrgId',
title: '根据组织过滤',
component: {
name: 'el-switch'
}
},
{
key: 'containInnerUse',
title: '是否包含内置用户',
......
......@@ -9,9 +9,10 @@
v-model="bindValue"
size="small"
filterable
:multiple="item.multiple"
:multiple="isMultiple"
remote
:remote-method="remoteMethod"
:loading="loading"
@change="UserChange"
>
<el-option
......@@ -53,11 +54,16 @@ export default {
data() {
return {
bindValue: '',
UserData: []
UserData: [],
loading: false
// secretCode: ''
}
},
computed: {},
computed: {
isMultiple() {
return this.item.multiple || this.$utils._get(this.item, 'component.multiple') || false
}
},
watch: {
// 'item.secret': {
// deep: true,
......@@ -84,7 +90,11 @@ export default {
deep: true,
handler: function(val) {
if (val !== this.bindValue) {
this.bindValue = val
if (!val || (this.$utils.isObect(val) && (Object.keys(val).length === 0))) {
this.bindValue = ''
} else {
this.bindValue = val
}
if (val || val === 0) {
let searchArray = []
if (this.$utils.isObect(val)) {
......@@ -126,21 +136,29 @@ export default {
if (query) {
// 针对审计页面查人
if (this.item.isAudPage) {
getFuzzyMatchUser(query).then(res => {
this.UserData = res.items ? res.items : []
})
this.loading = true
getFuzzyMatchUser(query)
.then(res => {
this.UserData = res.items ? res.items : []
})
.finally(() => {
this.loading = false
})
} else {
// 针对非审计页面查人
const params = { userAccount: query, containInnerUser: this.item.containInnerUse || false }
if (this.item.secret) {
params.secretCode = this.$store.state.user.userInfo.secretCode
}
getUsersByAccount(params).then(res => {
this.UserData = res.items ? res.items : []
})
this.loading = true
getUsersByAccount(params)
.then(res => {
this.UserData = res.items ? res.items : []
})
.finally(() => {
this.loading = false
})
}
} else {
this.UserData = []
}
},
UserChange(val) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment