From 2b480586814e907e6237a87f0022b92fa04dfe7a Mon Sep 17 00:00:00 2001
From: lty <876263681@qq.com>
Date: 星期三, 02 七月 2025 16:44:43 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/common/service/CommonService.java |    7 ++++---
 src/main/resources/application.yml                     |   10 ++++------
 2 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/src/main/java/com/zy/common/service/CommonService.java b/src/main/java/com/zy/common/service/CommonService.java
index 6eeffa5..45a495b 100644
--- a/src/main/java/com/zy/common/service/CommonService.java
+++ b/src/main/java/com/zy/common/service/CommonService.java
@@ -137,8 +137,11 @@
      */
     @Transactional
     public StartupDto getLocNoRun(Integer whsType, Integer staDescId, Integer sourceStaNo, String matnr, String batch, String grade, Integer moveCrnNo, LocTypeDto locTypeDto, int times) {
+        int tagId = 0;
         if (Cools.isEmpty(matnr)) {  //鐗╂枡鍙�
             matnr = "";
+        }else{
+            tagId = matService.getTagIdByMatnr(matnr);
         }
         if (Cools.isEmpty(batch)) {  //绠卞彿
             batch = "";
@@ -159,8 +162,6 @@
         int sRow = rowLastno.getsRow();
         int eRow = rowLastno.geteRow();
         int crnNumber = rowLastno.getCrnQty();
-
-        int tagId = matService.getTagIdByMatnr(matnr);
         if (Cools.isEmpty(rowLastno)) {
             throw new CoolException("鏁版嵁寮傚父锛岃鑱旂郴绠$悊鍛�");
         }
@@ -418,7 +419,7 @@
 //                return getLocNo(1, staDescId, sourceStaNo, matnr,batch,grade, locTypeDto, 0);
 //            }
             log.error("绯荤粺娌℃湁绌哄簱浣嶏紒锛侊紒 灏哄瑙勬牸锛� {}锛� 杞娆℃暟锛歿}", JSON.toJSONString(locTypeDto), times);
-            throw new CoolException("娌℃湁绌哄簱浣�");
+            throw new CoolException("娌℃湁绌哄簱浣嶆垨鍫嗗灈鏈哄紓甯�");
         }
         String locNo = locMast.getLocNo();
 
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index b9b17c4..9053b8d 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -109,9 +109,7 @@
   refreshtime: 0/5 * * * * ?
   db:
     driver_class_name: com.microsoft.sqlserver.jdbc.SQLServerDriver
-    url: jdbc:sqlserver://127.0.0.1:1433;databasename=TZGLLK
-    username: sa
-    password: sa@123
-#    url: jdbc:sqlserver://192.168.4.138:1433;databasename=XDLinkLK2
-#    username: sa
-#    password: sa@123
+    url: jdbc:sqlserver://192.168.16.202:9116;databasename=TZGLLK
+    username: GLLK
+    password: GLLK0626
+

--
Gitblit v1.9.1