Browse Source

优化pda扫码逻辑

jingbo 5 tháng trước cách đây
mục cha
commit
c5811c36ec

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

@@ -568,11 +568,11 @@ public class MesLineProcessController extends BaseController {
 			}
 
 			String fileName = file.getOriginalFilename();
-			if (fileName == null || !fileName.endsWith(".jar")) {
-				resp.setResult(Global.FALSE);
-				resp.setMessage("只能上传jar文件");
-				return resp;
-			}
+//			if (fileName == null || !fileName.endsWith(".jar")) {
+//				resp.setResult(Global.FALSE);
+//				resp.setMessage("只能上传jar文件");
+//				return resp;
+//			}
 
 			String id = request.getParameter("id");//工位主键ID
 			// 1. 获取旧的jar包路径,以便后续清理

+ 23 - 0
src/main/java/com/jeesite/modules/mes/web/MesProductRecordController.java

@@ -4157,6 +4157,29 @@ public class MesProductRecordController extends BaseController {
 		return resp;
 	}
 
+
+	// 将当前工位工件取消
+	@PostMapping(value = "cancelCurSn")
+	 @ResponseBody
+	 public CommonResp cancelCurSn(HttpServletRequest request) {
+		CommonResp<String> resp = new CommonResp<>();
+		String oprno = request.getParameter("oprno");
+		String lineSn = request.getParameter("lineSn");
+		if(StringUtils.isEmpty(oprno) || StringUtils.isEmpty(lineSn)){
+			resp.setResult(Global.FALSE);
+			resp.setMessage("参数错误");
+			return resp;
+		}
+		MesProcessProduct mesProcessProduct = new MesProcessProduct();
+		mesProcessProduct.setOprno(oprno);
+		mesProcessProduct.setProductCate(lineSn);
+		mesProcessProductService.updateSnIsNull(mesProcessProduct);
+		resp.setResult(Global.TRUE);
+		resp.setMessage("成功");
+		return resp;
+	}
+
+
 	// 客户端检查质量接口
 	@PostMapping(value = "pccheck")
 	@ResponseBody

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

@@ -3,7 +3,7 @@
 #======================================#
 
 # 产品或项目名称、软件开发公司名称
-productName: HEV&B13-MES生产管理系统
+productName: MES生产管理系统
 companyName: 安徽裕洋新能源科技有限公司
 
 # 产品版本、版权年份
@@ -55,12 +55,11 @@ jdbc:
   driver: com.mysql.cj.jdbc.Driver
   url: jdbc:mysql://127.0.0.1:3306/mes_cloud_dy?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
   #  url: jdbc:mysql://127.0.0.1:3306/mes_cloud_x04c?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
-  #  url: jdbc:mysql://192.168.9.181:3306/mes_cloud?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
-  #  username: mes_cloud
-  #  password: s2ENj7KaEySTC7dW
+#  url: jdbc:mysql://192.168.9.181:3306/mes_cloud?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
+#  username: mes_cloud
+#  password: s2ENj7KaEySTC7dW
   username: root
   password: root
-
   testSql: SELECT 1
 
   #  # Oracle 数据库配置(若使用 12c,请修改 /modules/core/pom.xml 文件,打开 12c 依赖,去掉 11g 依赖)
@@ -698,6 +697,7 @@ shiro:
     ${adminPath}/mes/mesProductRecord/pdaQueryIsSn = anon
     ${adminPath}/mes/mesProductRecord/pdaQueryQuality = anon
     ${adminPath}/mes/mesProductRecord/getCurSn= anon
+    ${adminPath}/mes/mesProductRecord/cancelCurSn= anon
     ${adminPath}/** = user