From e5161740b5be53690c672b727e74547ecbcab30c Mon Sep 17 00:00:00 2001
From: lyh <925863403@qq.com>
Date: 星期四, 05 六月 2025 09:20:58 +0800
Subject: [PATCH] 修改原有的电子样板检索

---
 lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DocInfoServiceImpl.java |   28 +++++++++++++++-------------
 1 files changed, 15 insertions(+), 13 deletions(-)

diff --git a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DocInfoServiceImpl.java b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DocInfoServiceImpl.java
index 3b4b965..32a53c1 100644
--- a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DocInfoServiceImpl.java
+++ b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DocInfoServiceImpl.java
@@ -159,19 +159,21 @@
             }
         }
         boolean saveBool = super.save(docInfo);
-        SysParams sysParams=sysParamsService.getSysPramBySettingKey("nc_dispatch_file");
-        if (sysParams ==null){
-            throw new JeecgBootException("鏈厤缃鍏C涓庣數瀛愬浘鐗堟槸鍚﹁Е鍙戝绛炬祦绋嬶紝璇疯仈绯荤鐞嗗憳");
-        }else {
-            if (saveBool&&sysParams.getSettingValue().equals("1")){
-                //瑙﹀彂瀹$
-                DispatchFile dispatchFile = new DispatchFile();
-                dispatchFile.setDocId(docInfo.getDocId());
-                dispatchFile.setFileId(docFile.getFileId());
-                dispatchFile.setAttributionId(uploadRequest.getAttributionId());
-                dispatchFile.setAttributionType(String.valueOf(uploadRequest.getAttributionType()));
-                dispatchFile.setDocClassCode(uploadRequest.getDocClassCode());
-                dispatchFileService.saveDispatchFile(dispatchFile);
+        if (uploadRequest.getDocClassCode().equals("NC")||uploadRequest.getDocClassCode().equals("other")){
+            SysParams sysParams=sysParamsService.getSysPramBySettingKey("nc_dispatch_file");
+            if (sysParams ==null){
+                throw new JeecgBootException("鏈厤缃鍏C涓庣數瀛愬浘鐗堟槸鍚﹁Е鍙戝绛炬祦绋嬶紝璇疯仈绯荤鐞嗗憳");
+            }else {
+                if (saveBool&&sysParams.getSettingValue().equals("1")){
+                    //瑙﹀彂瀹$
+                    DispatchFile dispatchFile = new DispatchFile();
+                    dispatchFile.setDocId(docInfo.getDocId());
+                    dispatchFile.setFileId(docFile.getFileId());
+                    dispatchFile.setAttributionId(uploadRequest.getAttributionId());
+                    dispatchFile.setAttributionType(String.valueOf(uploadRequest.getAttributionType()));
+                    dispatchFile.setDocClassCode(uploadRequest.getDocClassCode());
+                    dispatchFileService.saveDispatchFile(dispatchFile);
+                }
             }
         }
         return saveBool;

--
Gitblit v1.9.3