Commit c8acf41d zshaohui

1.xray skip展示问题修改

2.没有获取到库位号,inlistitem 修改为ng
1 个父辈 b8f51e01
...@@ -646,7 +646,7 @@ public class RobotBoxHandler extends BaseDeviceHandler { ...@@ -646,7 +646,7 @@ public class RobotBoxHandler extends BaseDeviceHandler {
// errorMsg = "[" + barcode.getBarcode() + "]未找到可用的[" + barcode.getPlateSize() + "x" + barcode.getHeight() + "]仓位"; // errorMsg = "[" + barcode.getBarcode() + "]未找到可用的[" + barcode.getPlateSize() + "x" + barcode.getHeight() + "]仓位";
errorMsg = "[" + barcode.getBarcode() + "]Not found available[" + size + "]Position"; errorMsg = "[" + barcode.getBarcode() + "]Not found available[" + size + "]Position";
resultMap.put("msg", errorMsg); resultMap.put("msg", errorMsg);
loadingUtil.updateItemState(barcode.getBarcode(),"",INITEM_STATUS.API001NG,errorMsg);
} }
} }
} catch (ValidateException ve) { } catch (ValidateException ve) {
...@@ -792,7 +792,7 @@ public class RobotBoxHandler extends BaseDeviceHandler { ...@@ -792,7 +792,7 @@ public class RobotBoxHandler extends BaseDeviceHandler {
} }
} else { } else {
barcode.setInListName(inList.getName()); barcode.setInListName(inList.getName());
loadingUtil.AddInListItem(rfid, barcode, "", INITEM_STATUS.PutIn); loadingUtil.AddInListItem(rfid, barcode, "", INITEM_STATUS.PutIn,barcode.isToXray());
} }
return barcode; return barcode;
......
...@@ -119,6 +119,11 @@ public class InListItem extends BasePo implements Serializable { ...@@ -119,6 +119,11 @@ public class InListItem extends BasePo implements Serializable {
*/ */
private List<ItemReelInfo> reelLists; private List<ItemReelInfo> reelLists;
/**
* 是否需要点料
*/
private Boolean toXray;
public void addReelInfo(ItemReelInfo reelInfo){ public void addReelInfo(ItemReelInfo reelInfo){
if(ObjectUtil.isEmpty(ri)){ if(ObjectUtil.isEmpty(ri)){
......
...@@ -85,7 +85,7 @@ public class LoadingController { ...@@ -85,7 +85,7 @@ public class LoadingController {
dto.setNg(dto.getNg() + 1); dto.setNg(dto.getNg() + 1);
}else if (item.isFailure()) { }else if (item.isFailure()) {
dto.setFailure(dto.getFailure() + 1); dto.setFailure(dto.getFailure() + 1);
} else if (item.isXray()) { } else if (item.getToXray() != null && !item.getToXray()) {
dto.setXRay(dto.getXRay() + 1); dto.setXRay(dto.getXRay() + 1);
} }
dtoMap.put(dto.getMaterialType(), dto); dtoMap.put(dto.getMaterialType(), dto);
...@@ -140,9 +140,12 @@ public class LoadingController { ...@@ -140,9 +140,12 @@ public class LoadingController {
is = true; is = true;
} else if (item.isFailure() && state.equalsIgnoreCase("failure")) { } else if (item.isFailure() && state.equalsIgnoreCase("failure")) {
is = true; is = true;
} else if (item.isXray() && state.equalsIgnoreCase("xray")) { } else if (item.getToXray() != null && !item.getToXray()) {
is = true; is = true;
} }
/*else if (item.isXray() && state.equalsIgnoreCase("xray")) {
is = true;
}*/
if (is) { if (is) {
Barcode code = barcodeManager.findByBarcode(item.getRi()); Barcode code = barcodeManager.findByBarcode(item.getRi());
......
...@@ -85,6 +85,37 @@ public class LoadingUtil { ...@@ -85,6 +85,37 @@ public class LoadingUtil {
} }
//获取库位号成功,增加一个正在入库的 //获取库位号成功,增加一个正在入库的
public void AddInListItem(String rfid, Barcode barcode, String posName, String state, Boolean toXray) {
InList inList = getInlist();
if (inList == null) {
return;
}
inList.addRfid(rfid);
inList.setStatus(INLIST_STATUS.ABNORMAL);
String mtype = MicronDataCache.GetReelType(barcode.getPlateSize(), barcode.getHeight());
log.info("为入库单[" + inList.getName() + "]增加一条入库信息:barcode[" + barcode.getBarcode() + "],mtype[" + mtype + "],pn[" + barcode.getPartNumber() + "],rfid[" + rfid + "],posName[" + posName + "],s[" + state + "]");
InListItem item = InListItem.newMItem(inList.getName(), barcode, rfid, posName, state, mtype);
if (inList.getEndRfidList() != null && inList.getEndRfidList().contains(rfid)) {
item.setRfidEnd(true);
}
if (toXray != null) {
item.setToXray(toXray);
}
item = inListItemManager.save(item);
List<InListItem> items = inList.getInListItems();
items.add(item);
inList.setInListItems(items);
inListManager.save(inList);
inListCache.addInListToMap(inList);
}
//获取库位号成功,增加一个正在入库的
public void AddInListItem(String rfid, Barcode barcode, String posName, String state){ public void AddInListItem(String rfid, Barcode barcode, String posName, String state){
AddInListItem(rfid,barcode,posName,state,""); AddInListItem(rfid,barcode,posName,state,"");
} }
...@@ -139,7 +170,11 @@ public class LoadingUtil { ...@@ -139,7 +170,11 @@ public class LoadingUtil {
updateItemState(barcode, "", s); updateItemState(barcode, "", s);
} }
public InListItem updateItemState( String barcode,String posName,String s) { public InListItem updateItemState( String barcode,String posName,String s){
return updateItemState(barcode,posName,s,"");
}
public InListItem updateItemState( String barcode,String posName,String s,String ngMsg) {
InList inList = getInlist(); InList inList = getInlist();
...@@ -157,6 +192,10 @@ public class LoadingUtil { ...@@ -157,6 +192,10 @@ public class LoadingUtil {
item.setPosName(posName); item.setPosName(posName);
} }
if (StringUtils.isNotBlank(ngMsg)){
item.setNgMsg(ngMsg);
}
update = true; update = true;
item.setState(s); item.setState(s);
item = inListItemManager.save(item); item = inListItemManager.save(item);
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!