From e7e36855180394b3004a610d70f92f7239925bbc Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期五, 01 十二月 2023 18:42:54 +0800
Subject: [PATCH] 规则基础配置模块代码上传

---
 Source/UBCS-WEB/src/components/FormTemplate/index.vue |   24 ++++++++++++++++++++----
 1 files changed, 20 insertions(+), 4 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/FormTemplate/index.vue b/Source/UBCS-WEB/src/components/FormTemplate/index.vue
index e0e0dc1..340f056 100644
--- a/Source/UBCS-WEB/src/components/FormTemplate/index.vue
+++ b/Source/UBCS-WEB/src/components/FormTemplate/index.vue
@@ -250,9 +250,11 @@
   },
   methods: {
     openDialog() {
+      //鏂板鍜屼慨鏀瑰叡鍚岃皟鐢�
       this.getFormTemplate();
-      if (this.type === "add") {
+      if (this.type === "add" || (this.type !== "add" && this.status === "amend")) {
         this.getCodeRule();
+        return;
       }
     },
     close() {
@@ -260,6 +262,7 @@
     },
     // 鎺ュ彛鑾峰彇琛ㄥ崟鏁版嵁
     getFormTemplate() {
+      //鏂板鍜屼慨鏀瑰叡鍚岃皟鐢�
       getFormTemplate({
         templateOid: this.templateOid,
         codeClassifyOid: this.codeClassifyOid,
@@ -277,6 +280,7 @@
             } else {
               this.showResembleQuery = false;
             }
+            //浼犻�掕〃鍗曚笂鏂瑰尯鍩熸暟鎹� 锛堟柊澧炲拰淇敼锛�
             this.$nextTick(() => {
               this.$refs.FormTemplate.templateRender(
                 res.data.formDefineVO.items
@@ -319,7 +323,7 @@
           that.secVOList = (res.data.data.secVOList || []).filter((item) =>
             typeList.includes(item.secType)
           );
-          if (that.secVOList.length > 0 && that.type === "add") {
+          if (that.secVOList.length > 0 && that.type === "add" ||(that.type !== "add" &&  that.status === "amend")) {
             that.showCodeApply = true;
             that.activeName = "codeApply";
 
@@ -372,7 +376,7 @@
       if (this.$refs.CodeApply) {
         this.$refs.CodeApply.changeChildItem(this.secVOList, this.TreeValue, this.type);
       }
-    },,
+    },
     //灞炴�х爜娈佃祴鍊�
     attrListForm(attrListForm) {
       this.attrList = attrListForm;
@@ -440,7 +444,18 @@
         );
       }
       // 鎺掗櫎涓�浜涘瓧娈�
-      const noData = [
+      const noData = this.status ? [
+        "jiliangdwname",
+        "materialtypeText",
+        "morengongysname",
+        "$caigouwl",
+        "$xiaoshouwl",
+        "$shifoupihaoguanli",
+        "lcstatus_text",
+        "hesuanfenleiname",
+        "$kucunwl",
+        "lastmodifier"
+      ] : [
         "jiliangdwname",
         "materialtypeText",
         "morengongysname",
@@ -453,6 +468,7 @@
         "oldcode",
         "lastmodifier"
       ];
+
       let resForm = {};
       const {defaultValue, formValue} = this.getDefaultValueAndFormValues(
         this.form

--
Gitblit v1.9.3