修改bug
This commit is contained in:
@@ -107,7 +107,7 @@ public class WorkOrderServiceImpl implements WorkOrdereService {
|
||||
for(int i=0;i<pcsn_num;i++){
|
||||
JSONObject jo = this.createPcsn(json);
|
||||
pcsn = jo.getString("pcsn");
|
||||
JSONObject old = mstTab.query("status<>'99' and material_id='"+material_id+"' and pcsn='"+pcsn+"'").uniqueResult(0);
|
||||
JSONObject old = mstTab.query("is_delete='0' and status<>'99' and material_id='"+material_id+"' and pcsn='"+pcsn+"'").uniqueResult(0);
|
||||
if(old!=null){
|
||||
throw new BadRequestException("已存在相同产品和批次的未完成工令!");
|
||||
}
|
||||
@@ -146,7 +146,7 @@ public class WorkOrderServiceImpl implements WorkOrdereService {
|
||||
String material_id = whereJson.getString("material_id");
|
||||
String pcsn = whereJson.getString("pcsn");
|
||||
String workorder_id = whereJson.getString("workorder_id");
|
||||
JSONObject old = mstTab.query("status<>'99' and material_id='"+material_id+"' and pcsn='"+pcsn+"' and workorder_id<>'"+workorder_id+"'").uniqueResult(0);
|
||||
JSONObject old = mstTab.query("is_delete='0' and status<>'99' and material_id='"+material_id+"' and pcsn='"+pcsn+"' and workorder_id<>'"+workorder_id+"'").uniqueResult(0);
|
||||
if(old!=null){
|
||||
throw new BadRequestException("已存在相同产品和批次的未完成工令!");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user