forked from github/dataease
feat(视图): 文本类型过滤组件支持枚举
This commit is contained in:
parent
721b2774fd
commit
dc36a06cb6
@ -217,6 +217,7 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
this.initOptions()
|
this.initOptions()
|
||||||
this.init()
|
this.init()
|
||||||
|
this.initEnumOptions()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
initOptions() {
|
initOptions() {
|
||||||
@ -234,10 +235,14 @@ export default {
|
|||||||
this.logic = this.item.logic
|
this.logic = this.item.logic
|
||||||
this.filterType = this.item.filterType
|
this.filterType = this.item.filterType
|
||||||
this.enumCheckField = this.item.enumCheckField
|
this.enumCheckField = this.item.enumCheckField
|
||||||
// 查找枚举的
|
},
|
||||||
|
initEnumOptions() {
|
||||||
|
// 查找枚举值
|
||||||
|
if (this.item.deType === 0 || this.item.deType === 5) {
|
||||||
multFieldValues([this.item.id]).then(res => {
|
multFieldValues([this.item.id]).then(res => {
|
||||||
this.fieldOptions = this.optionDatas(res.data)
|
this.fieldOptions = this.optionDatas(res.data)
|
||||||
})
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
optionDatas(datas) {
|
optionDatas(datas) {
|
||||||
if (!datas) return null
|
if (!datas) return null
|
||||||
|
Loading…
Reference in New Issue
Block a user