From 4604ab705afacf90abf2b961c4f06347e861c2aa Mon Sep 17 00:00:00 2001 From: songguoqiang <765017469@qq.com> Date: Tue, 12 Dec 2023 10:22:49 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=A1=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/spc/detectiontemplate/detectionTemplate.data.ts | 3 ++- src/views/spc/itembasic/index.vue | 5 +++++ src/views/spc/project/index.vue | 5 +++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/views/spc/detectiontemplate/detectionTemplate.data.ts b/src/views/spc/detectiontemplate/detectionTemplate.data.ts index 7fd57d3..c0347b5 100644 --- a/src/views/spc/detectiontemplate/detectionTemplate.data.ts +++ b/src/views/spc/detectiontemplate/detectionTemplate.data.ts @@ -31,7 +31,8 @@ export const DetectionTemplate = useCrudSchemas(reactive([ searchField: 'code', // 查询弹窗赋值字段 searchTitle: '物料信息', // 查询弹窗标题 searchAllSchemas: Itembasic.allSchemas, // 查询弹窗所需类 - searchPage: ItembasicApi.getItembasicPage // 查询弹窗所需分页方法 + searchPage: ItembasicApi.getItembasicPage, // 查询弹窗所需分页方法 + disabled:true } }, search: { diff --git a/src/views/spc/itembasic/index.vue b/src/views/spc/itembasic/index.vue index 61f85c0..57b299b 100644 --- a/src/views/spc/itembasic/index.vue +++ b/src/views/spc/itembasic/index.vue @@ -153,6 +153,11 @@ const openForm = (type: string, row?: any) => { // if(type=='update'){ // row.color = row.color.split(','); // } + if(type=='update'){ + Itembasic.allSchemas.formSchema[1].componentProps.disabled=true; + }else{ + Itembasic.allSchemas.formSchema[1].componentProps.disabled=false; + } basicFormRef.value.open(type, row) } diff --git a/src/views/spc/project/index.vue b/src/views/spc/project/index.vue index 8d1b0f6..9921a05 100644 --- a/src/views/spc/project/index.vue +++ b/src/views/spc/project/index.vue @@ -151,6 +151,11 @@ const buttonTableClick = async (val, row) => { /** 添加/修改操作 */ const basicFormRef = ref() const openForm = (type: string, row?: any) => { + if(type=='update'){ + Project.allSchemas.formSchema[0].componentProps.disabled=true; + }else{ + Project.allSchemas.formSchema[0].componentProps.disabled=false; + } basicFormRef.value.open(type, row) }