|
|
@@ -333,10 +333,6 @@ public class MESDataServiceImpl implements MESDataService {
|
|
|
String AE_MASTER = checkAccessKey(accessKey, requestId);
|
|
|
SpObserver.putSp(AE_MASTER);
|
|
|
Map<Object, Object> map = BaseUtil.parseFormStoreToMap(data);
|
|
|
- String maCode = StringUtil.nvl(map.get("maCode"), "");
|
|
|
- if ("".equals(maCode)){
|
|
|
- return ApiResponse.failRsp("10018","请指定工单!");
|
|
|
- }
|
|
|
String veCode = StringUtil.nvl(map.get("veCode"), "");
|
|
|
if ("".equals(veCode)){
|
|
|
return ApiResponse.failRsp("10011","供应商代码不能为空!");
|
|
|
@@ -361,11 +357,11 @@ public class MESDataServiceImpl implements MESDataService {
|
|
|
if ("".equals(QRCode)){
|
|
|
return ApiResponse.failRsp("10016","条码不能为空!");
|
|
|
}
|
|
|
- if (baseDao.checkIf("ProdQRCode","qr_macode='"+maCode+"' and qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0")){
|
|
|
- baseDao.execute("update ProdQRCode set qr_dcrischeck=-1,qr_dcrcheckres='OK',qr_dcrcheckdate=sysdate where qr_macode='"+maCode+"' and qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0");
|
|
|
+ if (baseDao.checkIf("ProdQRCode","qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0")){
|
|
|
+ baseDao.execute("update ProdQRCode set qr_dcrischeck=-1,qr_dcrcheckres='OK',qr_dcrcheckdate=sysdate where qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0");
|
|
|
return ApiResponse.successRsp("0","Success",requestId,"OK");
|
|
|
}else {
|
|
|
- baseDao.execute("update ProdQRCode set qr_dcrischeck=-1,qr_dcrcheckres='OK',qr_dcrcheckdate=sysdate where qr_macode='"+maCode+"' and qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0");
|
|
|
+ baseDao.execute("update ProdQRCode set qr_dcrischeck=-1,qr_dcrcheckres='OK',qr_dcrcheckdate=sysdate where qr_code='"+QRCode+"' and qr_vecode='" + veCode + "' and qr_prodcode='" + prodCode + "' and qr_machinecode='" + machineCode + "' and qr_version='" + version + "' and to_char(qr_date,'yyyy-MM-dd')='"+indate+"' and nvl(qr_isobtained,0)<>0");
|
|
|
return ApiResponse.successRsp("0", "Success", requestId, "NG");
|
|
|
}
|
|
|
}
|