修复字典组件值为整形不显示问题

master
RuoYi 3 years ago
parent 134835c870
commit 4e8c6fb7c0
  1. 6
      ruoyi-ui/src/components/DictTag/index.vue

@ -31,12 +31,12 @@ export default {
type: Array, type: Array,
default: null, default: null,
}, },
value: [String, Array], value: [Number, String, Array],
}, },
computed: { computed: {
values() { values() {
if (this.value) { if (this.value !== null && typeof this.value !== 'undefined') {
return Array.isArray(this.value) ? this.value : [this.value]; return Array.isArray(this.value) ? this.value : [String(this.value)];
} else { } else {
return []; return [];
} }

Loading…
Cancel
Save