From 35e4327b02b707bd51e233e8558f93f190457dcb Mon Sep 17 00:00:00 2001 From: dengbf Date: Wed, 7 May 2025 10:03:00 +0800 Subject: [PATCH] =?UTF-8?q?[=E4=BF=AE=E5=A4=8D]=20#[1415320533696512]?= =?UTF-8?q?=E5=B7=A5=E5=8D=95=E5=A4=84=E7=90=86-=E8=A1=A8=E5=8D=95?= =?UTF-8?q?=E4=B8=8B=E6=8B=89=E6=A1=86=E7=BB=84=E4=BB=B6=E5=BF=85=E5=A1=AB?= =?UTF-8?q?=EF=BC=8C=E7=BB=84=E4=BB=B6=E9=BB=98=E8=AE=A4=E5=80=BC=E7=9A=84?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=BA=90=E8=A2=AB=E5=88=A0=E9=99=A4=EF=BC=8C?= =?UTF-8?q?=E5=B7=A5=E5=8D=95=E6=B5=81=E8=BD=AC=E6=B2=A1=E6=9C=89=E6=A0=A1?= =?UTF-8?q?=E9=AA=8C=E7=BB=84=E4=BB=B6=E5=BF=85=E5=A1=AB=20http://192.168.?= =?UTF-8?q?0.96:8090/demo/rdm.html#/bug-detail/939050947543040/93905094754?= =?UTF-8?q?3057/1415320533696512?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../TsSheet/form/config/formselect-conf.vue | 35 ++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/src/resources/plugins/TsSheet/form/config/formselect-conf.vue b/src/resources/plugins/TsSheet/form/config/formselect-conf.vue index 66c1b92e..eaac3a71 100644 --- a/src/resources/plugins/TsSheet/form/config/formselect-conf.vue +++ b/src/resources/plugins/TsSheet/form/config/formselect-conf.vue @@ -39,7 +39,13 @@ required >
- +
0) { + if (!this.$utils.isEmpty(this.config.defaultValue)) { + if (this.config.defaultValue instanceof Array) { + let list = []; + this.config.defaultValue.forEach(d => { + if (val.find(v => v.value == d.value && v.text == d.text)) { + list.push(d); + } + }); + if (list.length > 0) { + this.$set(this.config, 'defaultValue', list); + } else { + this.$set(this.config, 'defaultValue', null); + } + } else { + if (!val.find(v => v.value == this.config.defaultValue.value && v.text == this.config.defaultValue.text)) { + this.$set(this.config, 'defaultValue', null); + } + } + } + } else { + this.$set(this.config, 'defaultValue', null); + } } }, filter: {}, -- Gitee