liuwei hace 1 día
padre
commit
336b747724

+ 5 - 2
src/main/java/com/jeesite/modules/mes/web/MesProductRecordController.java

@@ -1209,10 +1209,13 @@ public class MesProductRecordController extends BaseController {
 				if(StringUtils.isEmpty(cateSn)){
 					return "RS NS";
 				}
-				// 检验工件码(mes_product_model)
+				// 检验工件码:旧规则(前壳体/后面板) 或 mes_product_model 新码,任一满足即可
 				String checkProductSn = Global.getConfig("mes.check.productSn");
 				if(checkProductSn.equals("1")){
-					if(!mesProductModelService.checkSn(sn)){
+					Boolean qgxRet = CommonUitl.checkProductSnQgx(sn);
+					Boolean hmbRet = CommonUitl.checkProductSnHmb(sn);
+					Boolean modelRet = mesProductModelService.checkSn(sn);
+					if(!qgxRet && !hmbRet && !modelRet){
 						return "RS GS"; // 工件码格式不正确
 					}
 				}

+ 4 - 4
src/main/resources/config/application.yml

@@ -60,10 +60,10 @@ jdbc:
 #  url: jdbc:mysql://192.168.17.170:3306/mes_cloud_xz?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
 #  url: jdbc:mysql://192.168.100.128:3307/mes_cloud_xz?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
 
-#  username: mes_cloud_xz
-#  password: 2hNY3YMe2BGbCXLS
-  username: root
-  password: 123456
+  username: mes_cloud_xz
+  password: 2hNY3YMe2BGbCXLS
+#  username: root
+#  password: 123456
 
   testSql: SELECT 1