|
@@ -1209,13 +1209,10 @@ public class MesProductRecordController extends BaseController {
|
|
|
if(StringUtils.isEmpty(cateSn)){
|
|
if(StringUtils.isEmpty(cateSn)){
|
|
|
return "RS NS";
|
|
return "RS NS";
|
|
|
}
|
|
}
|
|
|
- // 检验工件码:兼容旧前壳体/后面板 + mes_product_model 新码(气密/螺套等走此路径)
|
|
|
|
|
|
|
+ // 检验工件码(mes_product_model)
|
|
|
String checkProductSn = Global.getConfig("mes.check.productSn");
|
|
String checkProductSn = Global.getConfig("mes.check.productSn");
|
|
|
if(checkProductSn.equals("1")){
|
|
if(checkProductSn.equals("1")){
|
|
|
- Boolean qgxRet = CommonUitl.checkProductSnQgx(sn);
|
|
|
|
|
- Boolean hmbRet = CommonUitl.checkProductSnHmb(sn);
|
|
|
|
|
- Boolean modelRet = mesProductModelService.checkSn(sn);
|
|
|
|
|
- if(!qgxRet && !hmbRet && !modelRet){
|
|
|
|
|
|
|
+ if(!mesProductModelService.checkSn(sn)){
|
|
|
return "RS GS"; // 工件码格式不正确
|
|
return "RS GS"; // 工件码格式不正确
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -3463,7 +3460,6 @@ public class MesProductRecordController extends BaseController {
|
|
|
|
|
|
|
|
@PostMapping(value = "ytresult2")
|
|
@PostMapping(value = "ytresult2")
|
|
|
@ResponseBody
|
|
@ResponseBody
|
|
|
- @Transactional
|
|
|
|
|
public CommonResp ytresult2(@RequestBody List<MesProductYtReq> mesProductYts, HttpServletRequest request) {
|
|
public CommonResp ytresult2(@RequestBody List<MesProductYtReq> mesProductYts, HttpServletRequest request) {
|
|
|
mesLogService.apisavexz(request);
|
|
mesLogService.apisavexz(request);
|
|
|
logger.info("mesProductReq:"+JSON.toJSONString(mesProductYts));
|
|
logger.info("mesProductReq:"+JSON.toJSONString(mesProductYts));
|
|
@@ -3601,9 +3597,9 @@ public class MesProductRecordController extends BaseController {
|
|
|
mesProductRecordService.updateRecordResult(request,sn,oprno,"100000","",result,oprno,params,lineSn,true,bmlists,"0");
|
|
mesProductRecordService.updateRecordResult(request,sn,oprno,"100000","",result,oprno,params,lineSn,true,bmlists,"0");
|
|
|
|
|
|
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
|
- logger.info(e.getMessage());
|
|
|
|
|
|
|
+ logger.error("ytresult2 fail sn="+sn+" oprno="+oprno, e);
|
|
|
resp.setMessage("操作失败");
|
|
resp.setMessage("操作失败");
|
|
|
- resp.setResult(Global.TRUE);
|
|
|
|
|
|
|
+ resp.setResult(Global.FALSE);
|
|
|
return resp;
|
|
return resp;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -3614,7 +3610,6 @@ public class MesProductRecordController extends BaseController {
|
|
|
|
|
|
|
|
@PostMapping(value = "ytresult3")
|
|
@PostMapping(value = "ytresult3")
|
|
|
@ResponseBody
|
|
@ResponseBody
|
|
|
- @Transactional
|
|
|
|
|
public CommonResp ytresult3(@RequestBody List<MesProductYtReq> mesProductYts, HttpServletRequest request) {
|
|
public CommonResp ytresult3(@RequestBody List<MesProductYtReq> mesProductYts, HttpServletRequest request) {
|
|
|
mesLogService.apisavexz(request);
|
|
mesLogService.apisavexz(request);
|
|
|
logger.info("mesProductReq3:"+JSON.toJSONString(mesProductYts));
|
|
logger.info("mesProductReq3:"+JSON.toJSONString(mesProductYts));
|
|
@@ -4352,7 +4347,8 @@ public class MesProductRecordController extends BaseController {
|
|
|
@Transactional
|
|
@Transactional
|
|
|
public String qmresult(MesProductQmReq mesProductQmReq,HttpServletRequest request) {
|
|
public String qmresult(MesProductQmReq mesProductQmReq,HttpServletRequest request) {
|
|
|
mesLogService.apisavexz(request);
|
|
mesLogService.apisavexz(request);
|
|
|
- String ldFlag = request.getParameter("ldFlag").trim();
|
|
|
|
|
|
|
+ String ldFlagParam = request.getParameter("ldFlag");
|
|
|
|
|
+ String ldFlag = ldFlagParam == null ? "" : ldFlagParam.trim();
|
|
|
String sn = mesProductQmReq.getSn();
|
|
String sn = mesProductQmReq.getSn();
|
|
|
String oprno = mesProductQmReq.getOprno();
|
|
String oprno = mesProductQmReq.getOprno();
|
|
|
String lineSn = mesProductQmReq.getLineSn();
|
|
String lineSn = mesProductQmReq.getLineSn();
|
|
@@ -4444,7 +4440,6 @@ public class MesProductRecordController extends BaseController {
|
|
|
|
|
|
|
|
@PostMapping(value = "xzqmresult")
|
|
@PostMapping(value = "xzqmresult")
|
|
|
@ResponseBody
|
|
@ResponseBody
|
|
|
- @Transactional
|
|
|
|
|
public CommonResp2 xzqmresult(@RequestBody MesProductXzQmReq2 mesProductXzQmReq, HttpServletRequest request) {
|
|
public CommonResp2 xzqmresult(@RequestBody MesProductXzQmReq2 mesProductXzQmReq, HttpServletRequest request) {
|
|
|
logger.info("xzqmresult:"+mesProductXzQmReq.toString());
|
|
logger.info("xzqmresult:"+mesProductXzQmReq.toString());
|
|
|
mesLogService.apisavexzJson(mesProductXzQmReq.getOprno(),mesProductXzQmReq.getLineSn(),mesProductXzQmReq.toString(),request);
|
|
mesLogService.apisavexzJson(mesProductXzQmReq.getOprno(),mesProductXzQmReq.getLineSn(),mesProductXzQmReq.toString(),request);
|
|
@@ -4517,8 +4512,7 @@ public class MesProductRecordController extends BaseController {
|
|
|
List<BindMaterialResp> bmlists = new ArrayList<>();
|
|
List<BindMaterialResp> bmlists = new ArrayList<>();
|
|
|
mesProductRecordService.updateRecordResult(null,sn,oprno,"100000","",content,userCode,params,lineSn,true,bmlists,"0");
|
|
mesProductRecordService.updateRecordResult(null,sn,oprno,"100000","",content,userCode,params,lineSn,true,bmlists,"0");
|
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
|
- e.printStackTrace();
|
|
|
|
|
-// return renderResult(Global.FALSE, text("操作失败!"));
|
|
|
|
|
|
|
+ logger.error("xzqmresult fail sn="+sn+" oprno="+oprno, e);
|
|
|
resp.setErrMsg("操作失败");
|
|
resp.setErrMsg("操作失败");
|
|
|
resp.setIsSuccess(false);
|
|
resp.setIsSuccess(false);
|
|
|
return resp;
|
|
return resp;
|