From c18afd50bfe43b834e723eeaa4de70f861d06a70 Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Wed, 5 Jun 2024 13:55:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=B3=E8=81=94=E8=A1=A8=E5=8D=95=E4=BC=98?= =?UTF-8?q?=E5=8C=96-app?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DesignForm/assembly/index.ts | 4 + src/components/DesignForm/formControlAttr.vue | 140 +++++++++++++++--- 2 files changed, 126 insertions(+), 18 deletions(-) diff --git a/src/components/DesignForm/assembly/index.ts b/src/components/DesignForm/assembly/index.ts index 1ed7649c8..7e025d1bf 100644 --- a/src/components/DesignForm/assembly/index.ts +++ b/src/components/DesignForm/assembly/index.ts @@ -99,6 +99,7 @@ export default [ control: { modelValue: '', glxxsz: [], + optionsValue3Formid:'', }, options: selectOption, // 下拉选项数据集合 config: config, @@ -116,6 +117,7 @@ export default [ control: { modelValue: [], glxxszForCheckBox: [], + optionsValue3Formid:'', }, options: selectOption, config: config, @@ -134,6 +136,7 @@ export default [ modelValue: '', appendToBody: true, glxxsz: [], + optionsValue3Formid:'', }, options: selectOption, config: config, @@ -700,6 +703,7 @@ export default [ dataRangeConditionHtml: '', dataRangeConditionHtmlCopy: '', saveFlag: false, + asfasfLabel:'', fillRoles: [ { leftValue: '', diff --git a/src/components/DesignForm/formControlAttr.vue b/src/components/DesignForm/formControlAttr.vue index 839490c07..cc9bf275f 100644 --- a/src/components/DesignForm/formControlAttr.vue +++ b/src/components/DesignForm/formControlAttr.vue @@ -619,19 +619,19 @@ path: 'config.componentName', vShow: ['component'] }, - { - label: '隐藏条件', + { + label: '关联表单', value: config.associatedForms, path: 'config.associatedForms', - type: 'associatedForms_hide', + type: 'associatedForms_form', vIf: state.isSearch, vShow: ['associatedForms'] }, - { - label: '关联表单', + { + label: '隐藏条件', value: config.associatedForms, path: 'config.associatedForms', - type: 'associatedForms_form', + type: 'associatedForms_hide', vIf: state.isSearch, vShow: ['associatedForms'] }, @@ -1906,9 +1906,22 @@ function getAsfasfFieldTree() { }); } +function getAsfasfFieldTreeOptionsValue3() { + return request({ + url: '/javasys/lowCode/AssociatedForms/getFieldTree', + method: 'post', + data: { + //cfid:'13' + cfid:controlData.value.control.optionsValue3Formid + }, + }); +} + const asfasfFieldTree = ref() +const asfasfFieldTreeOptionsValue3 = ref() + function formidChanged(){ if(controlData.value.control.formid===''){ @@ -1928,6 +1941,31 @@ function formidChanged(){ treeAttrs: data.treeAttrs, }] } + controlData.value.control.asfasfLabel = data.label + }); + } + +} + +function formidChangedOptionsValue3(){ + if(controlData.value.control.optionsValue3Formid===''){ + + }else{ + getAsfasfFieldTreeOptionsValue3().then(({ data }) => { + + if(data.id==="cfid为空"){ + //alert("cfid为空") + }else{ + let resData = ref(data.children) + //let rootid_ = data.value.label + asfasfFieldTreeOptionsValue3.value = [{ + id: 'rootid_'+data.label, + label: '关联的表单-'+data.label, + children: [...resData.value], + treeAttrs: data.treeAttrs, + }] + } + }); } } @@ -2263,6 +2301,14 @@ function delRole(id:String){ } } } +const associatedFormsChooseDialogFlag = ref(false) +function chooseAssociatedForm(){ + associatedFormsChooseDialogFlag.value = true +} +function handleDetermineAssociatedFormsChooseDialog(){ + associatedFormsChooseDialogFlag.value = false +} + //liwenxuan20240403 associatedForms end @@ -2373,6 +2419,14 @@ function deleteRowForGlxxsz(row: { id: any }){ } /* */ +const optionsValue3SettingDialogOpenFlag = ref(false) +function optionsValue3Setting(){ + optionsValue3SettingDialogOpenFlag.value = true +} +function handleDetermineoptionsValue3(){ + optionsValue3SettingDialogOpenFlag.value = false +} + //liwenxuan20240426 单选多选下拉 关联选项设置 end @@ -2842,18 +2896,8 @@ const loadNextPage = () => { -
- -
- + {{ controlData.control.asfasfLabel==''?'选择关联表单':controlData.control.asfasfLabel }} +
@@ -3035,6 +3079,7 @@ const loadNextPage = () => { @change="controlData.config.optionsFun = ''" > + @@ -3064,6 +3109,9 @@ const loadNextPage = () => { {{ controlData.type === 'cascader' ? '编辑' : '新增' }} + + + + + + + + + +