From e146bc181625aee75624f8364654721cfd886254 Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期五, 30 六月 2023 17:39:53 +0800
Subject: [PATCH] 修改部分空指针报错

---
 Source/UBCS-WEB/src/views/code/code.vue |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/Source/UBCS-WEB/src/views/code/code.vue b/Source/UBCS-WEB/src/views/code/code.vue
index 11a0b9a..ca5372d 100644
--- a/Source/UBCS-WEB/src/views/code/code.vue
+++ b/Source/UBCS-WEB/src/views/code/code.vue
@@ -1673,6 +1673,15 @@
             // 鐐瑰嚮鏂板鍩虹鐮佹,鍏抽棴绐楀彛涔嬪悗瑙﹀彂閲嶆柊鍔犺浇
             this.loadBasic(this.selectionList[0]);
           }else{
+            // 鍙兘鍙傜収寮曠敤鐨勪笟鍔$被鍨嬩細鍙戠敓鏀瑰彉鎵�浠ヨ繖鍎跨洿鎺ュreferConfig鐨刯son杩涜鏀瑰彉
+            let referConfig = JSON.parse(this.form.referConfig);
+            referConfig.referType = this.form.referBtmId;
+            referConfig.referTypeName = this.form.referBtmName;
+            this.form.referConfig = JSON.stringify(referConfig);
+
+            let referValueInfo = JSON.parse(this.form.referValueInfo);
+            referValueInfo.referType = this.form.referBtmId;
+            this.form.referValueInfo = JSON.stringify(referValueInfo);
             editSave(this.form).then(() => {
                // 鍏抽棴瀵硅瘽妗�
               this.addBasicCodeSettingBox = false
@@ -1960,11 +1969,9 @@
         },
         // 涓婄Щ涓嬬Щ鍩虹鐮佹
         upOrderNum(row){
-          //console.log(row.oid);
           if(!this.tipsMessage(this.selectionList)){
             return;
           }
-          let codeRuleOid = this.selectionList[0].oid;
           if (this.selectionList[0].lcStatus != 'Editing') {
             this.$message.warning("鍙湁缂栫爜瑙勫垯鐨勭姸鎬佹槸 [缂栬緫涓璢 鐨勬椂鍊欙紝鎵嶈兘璋冩暣鐮佹椤哄簭!");
             return; 
@@ -1974,7 +1981,7 @@
             return;        
           }
           upOrderNum(row.oid).then(() => {
-            this.loadBasic({"oid":codeRuleOid});
+            this.loadBasic(this.selectionList[0]);
             this.$message({
               type: "success",
               message: "鎿嶄綔鎴愬姛!"

--
Gitblit v1.9.3