ChoiceSetting support added, added captcha settings

This commit is contained in:
Henry Jameson 2023-03-20 23:36:47 +02:00
commit 0b5e536b4c
7 changed files with 121 additions and 13 deletions

View file

@ -11,7 +11,32 @@ export default {
...Setting.props,
options: {
type: Array,
required: true
required: false
},
optionLabelMap: {
type: Object,
required: false,
default: {}
}
},
computed: {
...Setting.computed,
realOptions () {
if (this.source === 'admin') {
console.log(this.backendDescriptionSuggestions)
return this.backendDescriptionSuggestions.map(x => ({
key: x,
value: x,
label: this.optionLabelMap[x] || x
}))
}
return this.options
}
},
methods: {
...Setting.methods,
getValue (e) {
return e
}
}
}