From a3337c98e0d090f87473bec5d597ed5a1cf38bce Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Thu, 30 May 2024 13:34:31 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9E=E7=8E=B0=E5=85=B3=E8=81=94=E8=A1=A8?= =?UTF-8?q?=E5=8D=95=E8=AE=BE=E7=BD=AE=E5=8F=AF=E9=80=89=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E4=B8=AD=E6=B2=A1=E6=9C=89=E5=BD=93=E5=89=8D=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E6=95=88=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DesignForm/formControlAttr.vue | 64 ++++++++++++++++--- src/widget/writingboard/vueSignature.vue | 2 +- 2 files changed, 57 insertions(+), 9 deletions(-) diff --git a/src/components/DesignForm/formControlAttr.vue b/src/components/DesignForm/formControlAttr.vue index 63faee8de..454b4e8c2 100644 --- a/src/components/DesignForm/formControlAttr.vue +++ b/src/components/DesignForm/formControlAttr.vue @@ -1609,7 +1609,8 @@ let currentUploadImgid = ""; //刚拖拽视频组件时,初始化imgid监听designForm.activeKey,变化时,如果controlData.value.type=='lowcodeCarsusel',就遍历轮播图数组把imgid=''的都生成uuid - watch(()=>store.activeKey, () => { + watch(()=>store.activeKey, (newVal) => { + //啊啊啊啊 if(controlData.value.type==='lowcodeCarsusel'){ const carsuselConfigData:CarsuselConfig[] = controlData.value.control.carsuselConfigArr carsuselConfigData.forEach(element => { @@ -1623,6 +1624,32 @@ }else if(controlData.value.type==='associatedForms'){ controlData.value.control.fillRoles[0].id = uuidv4().replaceAll('-','').toString(); } + //实现关联表单设置可选字段中没有当前字段效果 start + //console.log(controlData.value.name) + resDataForGlxxszExceptself1 = JSON.parse(JSON.stringify(resDataForGlxxszExceptself)); + //console.log(resDataForGlxxszExceptself1) + + for(let i = 0;i() const associatedFormsCurrentFormFieldTreeForGlxxsz = ref() +let associatedFormsCurrentFormFieldTreeForGlxxszExceptSelf = ref() +let resDataForGlxxszExceptself: any[] = [] +let resDataForGlxxszExceptself1: any[] = [] +let getAssociatedFormsCurrentFieldTreeData:any getAssociatedFormsCurrentFieldTree().then(({ data }) => { - + //console.log(data) + getAssociatedFormsCurrentFieldTreeData = JSON.parse(JSON.stringify(data)) + //console.log(getAssociatedFormsCurrentFieldTreeData) if(data.id==="cfid为空"){ //alert("cfid为空") }else{ @@ -1921,6 +1954,11 @@ getAssociatedFormsCurrentFieldTree().then(({ data }) => { let resDataForGlxxsz = ref(data.children.slice(8)) + resDataForGlxxszExceptself = JSON.parse(JSON.stringify(resDataForGlxxsz.value)); + + //console.log(resDataForGlxxszExceptself) + + associatedFormsCurrentFormFieldTreeForGlxxsz.value = [{ id: 'rootid_'+data.label, @@ -1929,6 +1967,15 @@ getAssociatedFormsCurrentFieldTree().then(({ data }) => { children: [...resDataForGlxxsz.value], treeAttrs: data.treeAttrs, }] + associatedFormsCurrentFormFieldTreeForGlxxszExceptSelf.value = [{ + id: 'rootid_'+data.label, + //label: '当前表单', + label: '当前表单-'+data.treeAttrs.show, + children: [...resDataForGlxxsz.value], + treeAttrs: data.treeAttrs,//getAssociatedFormsCurrentFieldTreeData + }] + + } }); @@ -2324,6 +2371,7 @@ function deleteRowForGlxxsz(row: { id: any }){ /* */ + //liwenxuan20240426 单选多选下拉 关联选项设置 end @@ -3799,7 +3847,7 @@ const loadNextPage = () => { @@ -3832,7 +3880,7 @@ const loadNextPage = () => { @@ -3869,11 +3917,11 @@ const loadNextPage = () => {