提交代码

main
userName 2025-08-09 11:31:42 +08:00
parent e32a4df085
commit 413818c1ce
28 changed files with 405 additions and 194 deletions

View File

@ -530,11 +530,11 @@ public class ItemJobLauncher implements ApplicationListener {
}
//发送失败的重新发送
public void resendAgvTask() {
synchronized("resendAgvTask") {
// synchronized("resendAgvTask") {
agvTaskManager.resendAgvTask();//发送失败的任务
agvTaskManager.urgentAgvTask(null);//加急
pickTicketManager.updateAGVTask();//重新生成agv任务
}
agvTaskManager.urgentAgvTask(null);//加急
// }
}
public void sapOutStatusOpen(){
//发料完成并SAP状态为3.

View File

@ -27,6 +27,7 @@ public interface LibraryTaskType {
public static String ddjb = "4";
/**任务执行*/
public static String rwzx = "1";
/**低*/
public static String rkqi = "3";
/**搬运指令*/

View File

@ -30,8 +30,8 @@ public interface STATUS {
/**
*
*/
public static String RECEIVED = "RECEIVED";//货架任务
public static String LOAD_COMPLETED = "LOAD_COMPLETED";//料箱任务
public static String RECEIVED = "RECEIVED";//货架完成
public static String LOAD_COMPLETED = "LOAD_COMPLETED";//料箱任务完成
/**
*

View File

@ -16,6 +16,7 @@ import com.dev.swms.server.model.base.Item;
import com.dev.swms.server.model.base.ItemAttach;
import com.dev.swms.server.model.base.ItemKey;
import com.dev.swms.server.model.base.LotInfo;
import com.dev.swms.server.model.base.MaterialFactory;
import com.dev.swms.server.model.base.NewLotInfo;
import com.dev.swms.server.model.base.PackageUnit;
import com.dev.swms.server.model.interfaceLog.InterfaceLog;
@ -201,4 +202,8 @@ public interface ItemManager extends BaseManager {
void refreshQty();
@Transactional
void addItemc(Long itemid,double c,double k,double g,double w,double b,Long zone_id);
@Transactional
void storeMaterialFactory(MaterialFactory mf);
}

View File

@ -2245,11 +2245,15 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
if(list.size()>0) {
continue;
}
String opName="多查询";
if(UserHolder.getUser()!=null) {
opName=UserHolder.getUser().getName();
}
if(jsa) {
//料箱 ,工作站 ,面 1=下发, 优先级 业务类型
callLocAndCallHJ(loc.getStock().getLP(), id,2l,1,1L,SlotType.callTaks,UserHolder.getUser().getName(),remarks);
callLocAndCallHJ(loc.getStock().getLP(), id,2l,1,1L,SlotType.callTaks,opName,remarks);
}else {
callLocAndCallHJ(loc.getStock().getLP(), id,2l,1,0L,SlotType.callTaks,UserHolder.getUser().getName(),remarks);
callLocAndCallHJ(loc.getStock().getLP(), id,2l,1,0L,SlotType.callTaks,opName,remarks);
}
}
}
@ -2282,11 +2286,24 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
Long lg=(new Date()).getTime();
logger.error("---OPEN--jiaji11111----"+lg);
if(ids==null||ids.size()==0) {
String hql=" select t.agvTask.id from Task t where t.waveDoc.id is not null and t.waveDoc.longtiem>0 "
+ " and DATEDIFF(MINUTE,t.dateBill1,GETDATE())>=(t.waveDoc.longtiem*60)"
String hql=" select t.agvTask.id from Task t where t.waveDoc.id >0 "
+ " and t.waveDoc.longtiem>0 and t.agvTask.status='ATCALL' "
+ " and t.planQuantity>0 and t.movedQuantityMU=0 and t.agvTask.jobPriorityType=0 "
+ " and t.agvTask.status='ATCALL' group by t.agvTask.id ";
+ " and DATEDIFF(MINUTE,t.dateBill1,GETDATE())>=(t.waveDoc.longtiem*60)"
+ " group by t.agvTask.id ";
List<Long> list=commonDao.findByQuery(hql);
// String sql=" select agv.id from task t " +
// " left join WAVE_DOC wd on wd.id=t.WAVE_DOC_ID " +
// " left join agvtask agv on agv.id=t.agvTask_ID " +
// " where t.WAVE_DOC_ID >0 and wd.longtiem>0 " +
// " and t.PLAN_QUANTITY>0 " +
// " and t.MOVED_QUANTITY_MU=0 " +
// " and agv.jobPriorityType=0 " +
// " and DATEDIFF(MINUTE,t.dateBill1,GETDATE())>=(wd.longtiem*60) " +
// " and agv.status='ATCALL' " +
// " group by agv.id ";
// List<Long> list = jdbcManager.getListLong(sql.toString());
if(list.size()>0) {
// agvStockJobPriorityType(list);
updateUrgentAgvTask(list);
@ -2336,9 +2353,10 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
boolean flag=false;
AgvTask agv=commonDao.load(AgvTask.class, id);
if(agv.isBeIssue()&&agv.getStatus().equals(STATUS.ATCALL)) {
if(agv.getJobPriorityType()>0&&agv.getJobPriority()>200) {
logger.error(agv.getRobotJobId()+"tiaoguo");
break;
if(agv.getJobPriorityType().intValue()==1&&agv.getJobPriority().intValue()>200) {
logger.error(agv.getRobotJobId()+"jiaji--------tiaoguo");
// break;
continue;
// agv.setJobPriorityType(1L);
// agv.setJobPriority(1000L+agv.getJobPriority());
}else {

View File

@ -1641,6 +1641,21 @@ public class DefaultItemManager extends DefaultBaseManager implements
}
public void storeMaterialFactory(MaterialFactory mf) {
String hql =" from ItemKey ik where ik.lotInfo.propC9='"+mf.getPlanCode()
+"' and ik.item.id="+mf.getItem().getId();
List<ItemKey> iks=commonDao.findByQuery(hql);
if(iks.size()>0) {
for(ItemKey ik:iks) {
ik.setBeMarkWeight(mf.isBeMarkWeight());
commonDao.store(ik);
}
}
commonDao.store(mf);
wmsOperationHisManager.storeOperationHis(mf.getId(),mf.getPlanCode(), null,"", "序列号调整", "修改",null,
null,0, 0,0, 0,mf.isBeMarkWeight()+ "", "WMS");
}
}

View File

@ -518,7 +518,7 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
receivedRecord.getItemKey(), receivedRecord.getReceiveDate(), null,
receivedRecord.getReceivedQuantity(), null, srcInv == null ? "" : srcInv.getStatus(),
srcInv == null ? 0L : srcInv.getId(), null, asn.getBillType(), userId1, receivedRecord.getBarCode(),
null,asn.getSourceType());
null,asn.getSourceType(),null);
if(item!=null&&receivedRecord.getLocation()!=null) {
Location location=commonDao.load(Location.class, receivedRecord.getLocation().getId());
item.setWarehouseArea(location.getZone());
@ -835,6 +835,9 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
String becode="";
for (Long id : ids) {
ReceivedRecord receivedRecord = commonDao.load(ReceivedRecord.class, id);
if(receivedRecord!=null&&receivedRecord.getReceivedQuantity()<=0) {
continue;
}
ASNDetail asnDetail = commonDao.load(ASNDetail.class, receivedRecord.getAsnDetail().getId());
ASN asn = commonDao.load(ASN.class, receivedRecord.getAsn().getId());
becode=asn.getCode()+asnDetail.getStrBill7();
@ -1058,8 +1061,11 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
jsonobj2.put("ZWERKSF", mdd.getStrBill9());// 发出工厂
jsonobj2.put("ZWERKST", mdd.getStrBill9());// 接收工厂
jsonobj2.put("MEINS", item.getUnit());
jsonobj2.put("SBBST", task.getItemKey().getLotInfo().getPropC3() == null ? ""
: task.getItemKey().getLotInfo().getPropC3() + "");
String PropC3=itemKey.getLotInfo().getPropC3() == null ? "" : itemKey.getLotInfo().getPropC3();
if(PropC3!=null&&PropC3.equals("E")) {
PropC3="";
}
jsonobj2.put("SBBST", PropC3);
jsonobj2.put("ZSONUM", task.getItemKey().getLotInfo().getPropC5() == null ? ""
: task.getItemKey().getLotInfo().getPropC5() + "");
}
@ -1081,8 +1087,11 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
jsonobj2.put("LGORT", itemKey.getLotInfo().getPropC2());
jsonobj2.put("LIFNR", itemKey.getLotInfo().getPropC5() == null ? "" : itemKey.getLotInfo().getPropC5());
jsonobj2.put("BWART", pickTicket.getSourceType());
jsonobj2.put("SOBKZ",
itemKey.getLotInfo().getPropC3() == null ? "" : itemKey.getLotInfo().getPropC3());
String PropC3=itemKey.getLotInfo().getPropC3() == null ? "" : itemKey.getLotInfo().getPropC3();
if(PropC3!=null&&PropC3.equals("E")) {
PropC3="";
}
jsonobj2.put("SOBKZ",PropC3);
jsonobj2.put("MEINS", item.getUnit());
jsonobj2.put("TKFIQ", task.getMovedQuantityMU() + "");
if(itemKey.isBeMarkWeight()) {
@ -1160,8 +1169,11 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
jsonobj2.put("LGORT", task.getItemKey().getLotInfo().getPropC2() == null ? ""
: task.getItemKey().getLotInfo().getPropC2() + "");
jsonobj2.put("MEINS", item.getUnit());
jsonobj2.put("SBBST", task.getItemKey().getLotInfo().getPropC3() == null ? ""
: task.getItemKey().getLotInfo().getPropC3() + "");
String PropC3=itemKey.getLotInfo().getPropC3() == null ? "" : itemKey.getLotInfo().getPropC3();
if(PropC3!=null&&PropC3.equals("E")) {
PropC3="";
}
jsonobj2.put("SBBST", PropC3);
jsonobj2.put("ZSONUM", task.getItemKey().getLotInfo().getPropC5() == null ? ""
: task.getItemKey().getLotInfo().getPropC5() + "");
if (pickTicket.getAllocatedQuantity() > pickTicket.getPickedQuantity()) {

View File

@ -1981,6 +1981,7 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
}
}
}
asnDetail.setSourceId(sourceId);
asnDetail.setLineNo(lineNo);
asnDetail.setZxmx(zxmx);
@ -2159,7 +2160,15 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
// List<Item> items=this.commonDao.findByQuery("from Item it where it.code='"+itemCode+"' ");
if(items.size()>0) {
Item ietm=items.get(0);
if(ietm.isBeMarkWeight()) {
boolean benmar=ietm.isBeMarkWeight();//序列号管理
String hqlitem=" from MaterialFactory p where p.item.id="+ietm.getId()+
" and p.planCode='"+propC9.trim()+"' ";
List<MaterialFactory> itempalns=commonDao.findByQuery(hqlitem);
if(itempalns.size()>0) {
MaterialFactory md=itempalns.get(0);
benmar=md.isBeMarkWeight();
}
if(benmar) {
if(strBill2==null||strBill2.length()==0) {
errorcode="205";
hs="0";
@ -2173,6 +2182,20 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
resultInfo.add(objectItem1);
continue;
}
} else {
if(strBill2!=null&&strBill2.length()>0) {
errorcode="205";
hs="0";
msg="失败";
JSONObject objectItem1=new JSONObject();
objectItem1.put("sourceId", sourceId);
objectItem1.put("lineNo", lineNo);
objectItem1.put("itemCode", itemCode);
objectItem1.put("errorcode", "205");
objectItem1.put("errordescr", "不是序列号管理的物料,不需要给序列号"+strBill2);
resultInfo.add(objectItem1);
continue;
}
}
}
@ -3247,14 +3270,13 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
libraryTask.setRelatedBill3(TaskStatus);
commonDao.store(libraryTask);
}else if (TaskStatus.equals(LibraryTaskType.ddwc)) {
libraryTask.setStatus(STATUS.ATWORK);//输送线上
libraryTask.setRelatedBill3(TaskStatus);
libraryTask.setArrivalDate(new Date());
commonDao.store(libraryTask);
}else if (TaskStatus.equals(LibraryTaskType.rwwc)) {
//LED显示信息,//完成
String str="";
@ -3270,8 +3292,9 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
libraryTask.setMes(str);
libraryTask.setRelatedBill3(TaskStatus);
msg=libraryTask.getId()+"";
//任务完成
//任务完成,更新状态
moveDocManager.finishLibraryTask(libraryTask.getId());
interfaceReqManager.receiveLEDinfo(libraryTask);
}else if (TaskStatus.equals(LibraryTaskType.ddjb)) {
libraryTask.setStatus(STATUS.ATWORK);//输送线上

View File

@ -9189,7 +9189,11 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
commonDao.store(ptd);
pt.setAllocatedQuantity(pt.getAllocatedQuantity()-quantity);
if(pt.getAllocatedQuantity()<=pt.getPickedQuantity()) {
if(pt.getAllocatedQuantity()<=0) {
pt.setStatus(PickTicketStatus.CLOSE);
}else {
pt.setStatus(PickTicketStatus.PICK_ALL);
}
}
commonDao.store(pt);
//取消电子标签任务
@ -9256,7 +9260,7 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
}else if(zone.getId()==1766) {
if (srcLocation.getStock() != null) {
// 判断该工作站是否还需要该托盘,需要则不改变任何
if(t.getLibraryTask()!=null) {
List<Task> syts = this.commonDao
.findByQuery("from Task t where t.agvStatus=2 and t.libraryTask.id="+t.getLibraryTask().getId());
if (syts.size() > 0) {
@ -9267,6 +9271,7 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
lt.setStatus(STATUS.RECEIVED);
this.commonDao.store(lt);
}
}
}
}
if(inventory!=null){
@ -9275,8 +9280,8 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
Location loc=commonDao.load(Location.class,inventory.getLocation().getId());
inventoryManager.addInventoryLog(InventoryLogType.COMPANY_TRANS_IN, 1, pt.getCode(), loc, null,
ik, inventory.getStorageDate(), inventory.getSOI(), quantity, null,
inventory.getStatus(), inventory.getId(), "取消分配", bt, userId, inventory.getBarCode(),
loc,pt.getSourceType());
inventory.getStatus(), inventory.getId(), "跳过任务", bt, userId, inventory.getBarCode(),
loc,pt.getSourceType(),ptd.getLocType());
}
// shuaxinPick(pt);//刷新出库单 分配数量
//回传SAP
@ -9321,9 +9326,11 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
if(tasks4.size()==0) {
if(bt.getCode().equals("GPUTPTC")) {
//工单出库
interfaceReqManager.wmsSapCancelStatus(ptd.getSourceId() == null ? "" : ptd.getSourceId(), ptd.getStrBill1() == null ? "" : ptd.getStrBill1(),
"0", billCode, "", 2);
List<Long> tasks3 = commonDao.findByQuery("select p.id from Task p where p.planQuantity>0 and p.pickTicketDetail.pickTicket.id=" + pt.getId());
List<Long> tasks3 = commonDao.findByQuery("select p.id from Task p where p.planQuantity>0 and "
+ "p.pickTicketDetail.pickTicket.id=" + pt.getId()+" and p.popular=0 ");
if(tasks3.size()==0) {
interfaceReqManager.wmsSapCancelStatus(ptd.getSourceId() == null ? "" : ptd.getSourceId(), ptd.getStrBill1() == null ? "" : ptd.getStrBill1(),
"0", billCode, "", 3);

View File

@ -364,7 +364,7 @@ public interface InventoryManager extends BaseManager{
InventoryLog addInventoryLog(String logType, int incOrDec, String relatedBill, Location location,
String LP, ItemKey itemKey, Date storageDate, String soi, double occurQuantity, PackageUnit unit,
String status, Long referenceLog, String description, BillType billType,long userId,
String serial,Location srcLoc,String strbill1);
String serial,Location srcLoc,String strbill1,String strbill2);

View File

@ -190,7 +190,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
public InventoryLog addInventoryLog(String logType, int incOrDec, String relatedBill, Location location,
String LP, ItemKey itemKey, Date storageDate, String soi, double occurQuantity, PackageUnit unit,
String status, Long referenceLog, String description, BillType billType,long userId,
String serial,Location srcLoc,String strbill1) {
String serial,Location srcLoc,String strbill1,String strbill2) {
InventoryLog log = EntityFactory.getEntity(InventoryLog.class);
log.setLogType(logType);
log.setIncOrDec(incOrDec);
@ -206,6 +206,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
log.setLP(LP);
log.setStatus(status);
log.setStrbill1(strbill1);
log.setStrbill2(strbill2);
log.setReferenceLog(referenceLog);
if(userId>0){
Worker w=this.load(Worker.class, userId);
@ -276,7 +277,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
//写库存日志
addInventoryLog(InventoryLogType.RECEIVING, 1, relatedBill, location, (stock==null?null:stock.getLP()),
inventory.getItemKeyInventory().getItemKey(), receiveDate, relatedBill, quantity, packageUnit,
inventory.getStatus(), null, null, billType,0,inventory.getBarCode(),null,null);
inventory.getStatus(), null, null, billType,0,inventory.getBarCode(),null,null,null);
}
public void receiving(Location loc, ItemKey itemKey, double quantity, PackageUnit pu, Date receiveDate,String logType,String operator) {
@ -433,7 +434,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
storeItemKeyInventory(itemKeyInventory);
addInventoryLog(InventoryLogType.RECEIVING_ADJUST, incOrDec, soi, location,
(stock==null?null:stock.getLP()), inventory.getItemKeyInventory().getItemKey(), storageDate,
soi, quantity, packageUnit, inventory.getStatus(), null, null, billType,0,inventory.getBarCode(),null,null);
soi, quantity, packageUnit, inventory.getStatus(), null, null, billType,0,inventory.getBarCode(),
null,null,null);
}
public void receivingAdjust(Long locationId, ItemKey itemKey, double quantity,String soi,String operator) {
@ -503,7 +505,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(InventoryLogType.SHIPPING_ADJUST, incOrDec, relatedBill, location,
(stock==null?null:stock.getLP()), inventory.getItemKeyInventory().getItemKey(),
storageDate, soi, quantity*packageUnit.getConvertFigure(), packageUnit,
inventory.getStatus(), null, description, billType,0,inventory.getBarCode(),null,null);
inventory.getStatus(), null, description, billType,0,inventory.getBarCode(),null,null,null);
}
private Inventory adjustInventoryAdd(Location location, ItemKey itemKey, double quantity,
@ -548,7 +550,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(logType, incOrDec, relatedBill, inventory.getLocation(),
(stock==null?null:stock.getLP()), inventory.getItemKey(),
storageDate, soi, Math.abs(quantity), inventory.getPackageUnit(),
inventory.getStatus(), null, description, billType,0,inventory.getBarCode(),null,null);
inventory.getStatus(), null, description, billType,0,inventory.getBarCode(),null,null,null);
}
return inventory;
}
@ -572,7 +574,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
if(inventory.getQueuedQuantity()==0) {
List<Inventory> invs=commonDao.findByQuery(hql);
this.addInventoryLog(InventoryLogType.MOVE, 1, inventory.getSOI(), l, "", inventory.getItemKey(),
inventory.getStorageDate(), inventory.getSOI(), packQty, null, inventory.getStatus(), inventory.getId(), "移库位", null,0,inventory.getBarCode(),null,null);
inventory.getStorageDate(), inventory.getSOI(), packQty, null, inventory.getStatus(),
inventory.getId(), "移库位", null,0,inventory.getBarCode(),null,null,null);
if(invs.size()>0) {
Inventory inv=invs.get(0);
if(inv.getId()==inventoryId) {
@ -621,7 +624,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
if(inv.getQueuedQuantity()==0) {
this.addInventoryLog(InventoryLogType.COUNT_ADJUST, -1, inv.getSOI(), inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "删除库存", null,0,
inv.getBarCode(),null,null);
inv.getBarCode(),null,null,null);
commonDao.delete(inv);
loc.setStatus(WarehouseAreaStatus.FREE);
commonDao.store(loc);
@ -650,7 +653,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
(inventory.getLP()==null?null:inventory.getLP().getLP()),
inventory.getItemKey(), inventory.getStorageDate(), inventory.getSOI(),
quantity, inventory.getPackageUnit(), inventory.getStatus(), inventory.getId(),
description, null,0,inventory.getBarCode(),null,null);
description, null,0,inventory.getBarCode(),null,null,null);
}
/*
@ -712,7 +715,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
destLocation, (srcInventory.getLP()==null?null:srcInventory.getLP().getLP()),
ik, srcInventory.getStorageDate(),
srcInventory.getSOI(), quantity, null, srcInventory.getStatus(), srcInventory.getId(),
"移位", billType,workerId,srcInventory.getBarCode(),srcLocation,null);
"移位", billType,workerId,srcInventory.getBarCode(),srcLocation,null,null);
}
@ -981,7 +984,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(str, 1, "",
deslocation, (srcInv.getLP()==null?null:srcInv.getLP().getLP()),
itemKey, srcInv.getStorageDate(),
srcInv.getSOI(), quantity, null, srcInv.getStatus(), srcInv.getId(), "移位", null,workerId,srcInv.getBarCode(),srcInv.getLocation(),null);
srcInv.getSOI(), quantity, null, srcInv.getStatus(), srcInv.getId(), "移位",
null,workerId,srcInv.getBarCode(),srcInv.getLocation(),null,null);
}
@ -1039,12 +1043,12 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
srcInventory.getLocation(), (srcInventory.getLP()==null?null:srcInventory.getLP().getLP()),
srcInventory.getItemKeyInventory().getItemKey(), srcInventory.getStorageDate(),
srcInventory.getSOI(), convertQtyMU, destPackageUnit, srcInventory.getStatus(),
null, null, null,0,srcInventory.getBarCode(),null,null);
null, null, null,0,srcInventory.getBarCode(),null,null,null);
addInventoryLog(InventoryLogType.CONVERT_PACKAGEUNIT, 1, null,
dstPackInventory.getLocation(), (dstPackInventory.getLP()==null?null:dstPackInventory.getLP().getLP()),
dstPackInventory.getItemKeyInventory().getItemKey(), dstPackInventory.getStorageDate(),
dstPackInventory.getSOI(), convertQtyMU, destPackageUnit, dstPackInventory.getStatus(),
null, null, null,0,dstPackInventory.getBarCode(),null,null);
null, null, null,0,dstPackInventory.getBarCode(),null,null,null);
}
/*
@ -1078,7 +1082,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(InventoryLogType.SHIPPING, -1, relatedBill, location, (stock==null?null:stock.getLP()),
inventory.getItemKeyInventory().getItemKey(), storageDate, soi,
quantity*packageUnit.getConvertFigure(), packageUnit, inventory.getStatus(), null, null, billType,0,inventory.getBarCode(),null,null);
quantity*packageUnit.getConvertFigure(), packageUnit, inventory.getStatus(),
null, null, billType,0,inventory.getBarCode(),null,null,null);
}
/*
@ -1104,7 +1109,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
inventory.getLocation(), (inventory.getLP()==null?null:inventory.getLP().getLP()),
inventory.getItemKeyInventory().getItemKey(), inventory.getStorageDate(), inventory.getSOI(),
Math.abs(oldQuantity), inventory.getPackageUnit(), inventory.getStatus(), null, description, null,
0,inventory.getBarCode(),null,null);
0,inventory.getBarCode(),null,null,null);
}
}
@ -1396,7 +1401,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
srcInventory.getItemKeyInventory().getItemKey(),
srcInventory.getStorageDate(), processDoc.getCode(),
quantity*srcInventory.getPackageUnit().getConvertFigure(), srcInventory.getPackageUnit(),
srcInventory.getStatus(), null, null, processDoc.getBillType(),0,srcInventory.getBarCode(),null,null);
srcInventory.getStatus(), null, null, processDoc.getBillType(),0,srcInventory.getBarCode(),
null,null,null);
}
/*
@ -1427,7 +1433,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(InventoryLogType.PROCESS_UP, 1, processDoc.getCode(), location,
(stock==null?null:stock.getLP()), inventory.getItemKeyInventory().getItemKey(), receiveDate,
processDoc.getCode(), quantity*packageUnit.getConvertFigure(), packageUnit,
inventory.getStatus(), null, null, processDoc.getBillType(),0,inventory.getBarCode(),null,"");
inventory.getStatus(), null, null, processDoc.getBillType(),0,inventory.getBarCode(),null,"",null);
}
/*
@ -1489,12 +1495,12 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
iv.getLP(), iv.getStatus(), storageDate, iv.getSOI(), Boolean.FALSE);
InventoryLog log1 = addInventoryLog(InventoryLogType.MODIFY_LOT, 1, null, iv.getLocation(),
(iv.getLP()==null?null:iv.getLP().getLP()), dbItemKey, iv.getStorageDate(), iv.getSOI(),
newQty, iv.getPackageUnit(), iv.getStatus(), null, null, null,0,iv.getBarCode(),null,"");
newQty, iv.getPackageUnit(), iv.getStatus(), null, null, null,0,iv.getBarCode(),null,"",null);
//扣减原批次库存
adjustInventoryUpdateWithNoLog(iv, oldQty);
addInventoryLog(InventoryLogType.MODIFY_LOT, -1, null, iv.getLocation(),
iv.getLP()==null?null:iv.getLP().getLP(), iv.getItemKeyInventory().getItemKey(), iv.getStorageDate(),
iv.getSOI(), newQty, iv.getPackageUnit(), iv.getStatus(), log1.getId(), null, null,0,iv.getBarCode(),null,null);
iv.getSOI(), newQty, iv.getPackageUnit(), iv.getStatus(), log1.getId(), null, null,0,iv.getBarCode(),null,null,null);
}
LocalizedMessage.addMessage("itemKey.already.modify", new String[] {dbItemKey.getLot()});
}
@ -2429,7 +2435,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(InventoryLogType.COMPANY_TRANS_IN, 1, null, inv1.getLocation(),
(inv1.getLP()==null?null:inv1.getLP().getLP()), iki1.getItemKey(),
inv1.getStorageDate(), inv1.getSOI(), transQuantity, inv1.getPackageUnit(),
inv1.getStatus(), null, Inventory.COMPANY_TRANS_IN, null,0,inv1.getBarCode(),null,null);
inv1.getStatus(), null, Inventory.COMPANY_TRANS_IN, null,0,inv1.getBarCode(),null,null,null);
//转出货主的库存(删除库存记录、增加“货权转出”库存日志)
ItemKeyInventory iki2 = inventory.getItemKeyInventory();
@ -2437,7 +2443,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
addInventoryLog(InventoryLogType.COMPANY_TRANS_OUT, -1, null, inventory.getLocation(),
(inventory.getLP()==null?null:inventory.getLP().getLP()), iki2.getItemKey(),
inventory.getStorageDate(), inventory.getSOI(), transQuantity, inventory.getPackageUnit(),
inventory.getStatus(), null, Inventory.COMPANY_TRANS_OUT, null,0,inventory.getBarCode(),null,null);
inventory.getStatus(), null, Inventory.COMPANY_TRANS_OUT, null,0,inventory.getBarCode(),null,null,null);
}
private Item canTrans(Item itemA,Structure companyB){
@ -2823,12 +2829,12 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
newInv.add(qty,0,0);
InventoryLog log1 = addInventoryLog(InventoryLogType.MODIFY_STATUS, 1, null, inv.getLocation(),
(inv.getLP()==null?null:inv.getLP().getLP()),inv.getItemKeyInventory().getItemKey(), inv.getStorageDate(), inv.getSOI(),
qty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null,0,inv.getBarCode(),null,null);
qty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null,0,inv.getBarCode(),null,null,null);
}
if(invs.size()>0){
InventoryLog log1 = addInventoryLog(InventoryLogType.MODIFY_STATUS, -1, null, inv.getLocation(),
(inv.getLP()==null?null:inv.getLP().getLP()),inv.getItemKeyInventory().getItemKey(), inv.getStorageDate(), inv.getSOI(),
oldQty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null ,0,inv.getBarCode(),null,null);
oldQty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null ,0,inv.getBarCode(),null,null,null);
if(oldQty<=0){
this.commonDao.delete(inv);
}else{
@ -2837,7 +2843,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
}else{
InventoryLog log1 = addInventoryLog(InventoryLogType.MODIFY_STATUS, 0, null, inv.getLocation(),
(inv.getLP()==null?null:inv.getLP().getLP()),inv.getItemKeyInventory().getItemKey(), inv.getStorageDate(), inv.getSOI(),
qty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null,0,inv.getBarCode(),null,null);
qty, inv.getPackageUnit(), inv.getStatus(), null,"调整为"+status, null,0,inv.getBarCode(),null,null,null);
inv.setStatus(status);
this.commonDao.store(inv);
}
@ -3004,7 +3010,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
commonDao.store(item);
//写入库存日志
this.addInventoryLog(InventoryLogType.SHIPPING_ADJUST, -1, inv.getSOI(), inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), outQty, null, inv.getStatus(), inv.getId(), "其它出库", null,0,inv.getBarCode(),null,null);
inv.getStorageDate(), inv.getSOI(), outQty, null, inv.getStatus(), inv.getId(), "其它出库", null,0,
inv.getBarCode(),null,null,null);
if(inv.getQuantity()==0){
Location loc=inv.getLocation();
commonDao.delete(inv);
@ -3054,7 +3061,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
commonDao.store(item);
//写入库存日志
this.addInventoryLog(InventoryLogType.PROCESS_UP, 1, inv.getSOI(), inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inQty, null, inv.getStatus(), inv.getId(), "补货入库", null,0,inv.getBarCode(),null,null);
inv.getStorageDate(), inv.getSOI(), inQty, null, inv.getStatus(), inv.getId(), "补货入库", null,0,
inv.getBarCode(),null,null,null);
InterfaceManager interfaceManager = (InterfaceManager)ac.getBean("interfaceManager");
List<String> robotJobIds=new ArrayList<String>();
String xmlInfo=interfaceManager.returnAGVJSON(robotJobIds, 1, inv.getLocation().getCode(), false, "RETURN_WAREHOUSE");
@ -3111,7 +3119,7 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
Inventory inv=this.load(Inventory.class, inventoryId);
this.addInventoryLog(InventoryLogType.INVENTORY_ADJUST, -1, inv.getSOI(), inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "调整库存"+description, null,0,
inv.getBarCode(),null,null);
inv.getBarCode(),null,null,null);
inv.setQueuedQuantity(packQty1);//占用数量
@ -3154,7 +3162,9 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
inv.setItemKey(itemKey);
commonDao.store(inv);
addInventoryLog(InventoryLogType.INVENTORY_ADJUST, 1, "", inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "批次调整", null,0,inv.getBarCode(),null,null);
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null,
inv.getStatus(), inv.getId(), "批次调整", null,0,inv.getBarCode(),
null,null,null);
}else {
throw new BusinessException(propC1+" 格式错误");
}
@ -3180,7 +3190,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
inv.setDescription(des);
commonDao.store(inv);
addInventoryLog(InventoryLogType.FROZEN, 1, "", inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "冻结", null,0,inv.getBarCode(),null,null);
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(),
inv.getId(), "冻结", null,0,inv.getBarCode(),null,null,null);
}
}
}
@ -3196,7 +3207,8 @@ public class DefaultInventoryManager extends DefaultBaseManager implements Inven
inv.setDescription(null);
commonDao.store(inv);
addInventoryLog(InventoryLogType.FROZEN, 1, "", inv.getLocation(), null, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "解冻", null,0,inv.getBarCode(),null,null);
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(),
inv.getId(), "解冻", null,0,inv.getBarCode(),null,null,null);
}
}
}

View File

@ -3829,7 +3829,7 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
inventoryManager.addInventoryLog(InventoryLogType.COMPANY_TRANS_IN, 1, pt.getCode(), loc, null,
ik, inventory.getStorageDate(), inventory.getSOI(), quantity, null,
inventory.getStatus(), inventory.getId(), "取消分配", bt, UserHolder.getUser().getId(), inventory.getBarCode(),
loc,pt.getSourceType());
loc,pt.getSourceType(),ptd.getLocType());
}
//回传SAP

View File

@ -197,7 +197,7 @@ public class DefaultASNManager extends DefaultBaseManager implements ASNManager
if(asnDetail.getExpectedQuantity()<asnDetail.getReceivedQuantity()) {
throw new BusinessException("需求数量不能小于已整理数量");
}
if(item.isBeMarkWeight()) {
if(updateBeMarkWeight(asnDetail)) {
asnDetail.setExpectedQtyOfMasterUnit(1D);//入库数量
asnDetail.setExpectedQuantity(asnDetail.getExpectedQtyOfMasterUnit());
if((asnDetail.getStrBill2()==null||asnDetail.getStrBill2().equals(""))) {
@ -2332,6 +2332,9 @@ public void addASNDetail(Long id,ASNDetail asnDetail) {
Long workerId,long dock_id,Long zone_id,double receivedQuantity,long stockId,
Long pqty,String mac,String statusDes,boolean agv) throws Exception{
// logger.info(asnDetailIds+"--整理11+"+new Date());
if(receivedQuantity<=0) {
throw new BusinessException("整理数量必须大于0");
}
for(Long id:asnDetailIds){//循环整理(收货)
ASNDetail asnDetail=this.load(ASNDetail.class, id);//根据整理的这条数据获取它所有的明细
ASN asn=commonDao.load(ASN.class, asnDetail.getAsn().getId());
@ -2342,6 +2345,7 @@ public void addASNDetail(Long id,ASNDetail asnDetail) {
if(receivedQuantity>f1){
throw new BusinessException("总数量不能大于订单数量"+asnDetail.getUnReceivedQuantity());
}
BillType bt=commonDao.load(BillType.class, asn.getBillType().getId());
Item item=this.load(Item.class, asnDetail.getItem().getId());//货品
WarehouseArea warehouseArea =commonDao.load(WarehouseArea.class, zone_id);//库区
@ -2419,7 +2423,7 @@ public void addASNDetail(Long id,ASNDetail asnDetail) {
}
}
}
if(item.isBeMarkWeight()) {
if(asnDetail.isBeMarkWeight()) {
List<Inventory> invs=commonDao.findByQuery(" from Inventory inv where inv.barCode='"+asnDetail.getStrBill2()+"'"
+ " and inv.itemKey.item.id="+item.getId()+" and inv.quantity>0 "
+ " and inv.status in('已入库','待上架','已出库','冻结','整理中')");
@ -4684,7 +4688,7 @@ public void addASNDetail(Long id,ASNDetail asnDetail) {
inventoryManager.addInventoryLog(InventoryLogType.RECEIVING, 1, asn.getRelatedBill1(), loc, (inventory.getLP() == null ? null
: inventory.getLP().getLP()), inventory.getItemKey(), inventory.getStorageDate(), inventory.getSOI(), receivedRecord.getReceivedQuantity(),
null, inventory.getStatus(), inventory.getId(), "成品入库", asn.getBillType(),workerId, inventory.getBarCode(),
ad.getDock(),asn.getSourceType());
ad.getDock(),asn.getSourceType(),null);
asn.setPutawayQuantity(asn.getPutawayQuantity()+receivedRecord.getReceivedQuantity());
commonDao.store(asn);
@ -4736,7 +4740,7 @@ public void addASNDetail(Long id,ASNDetail asnDetail) {
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_DOWN, -1, asn.getRelatedBill1(), inventory.getLocation(), (inventory.getLP() == null ? null
: inventory.getLP().getLP()), inventory.getItemKey(), inventory.getStorageDate(), inventory.getSOI(), inventory.getQuantity(),
null, inventory.getStatus(), inventory.getId(), "取消整理", asn.getBillType(),0, inventory.getBarCode(),
ad.getDock(),asn.getSourceType());
ad.getDock(),asn.getSourceType(),null);
commonDao.delete(inventory);
}
}else{

View File

@ -1344,7 +1344,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
inventoryManager.addInventoryLog(str, 1, moveDocCode, deslocation, (srcInv.getLP() == null ? null
: srcInv.getLP().getLP()), itemKey, srcInv.getStorageDate(), srcInv.getSOI(), toBeMovedQty,
null, srcInv.getStatus(), srcInv.getId(), "移位", billType, userId, srcInv.getBarCode(),
srclocation,moveDoc.getWhCode());
srclocation,moveDoc.getWhCode(),null);
commonDao.delete(srcInv);
}
if (moveQuantity > 0) {
@ -2325,7 +2325,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
srcInv.getLocation(), (rd.getSrcLP() == null ? null : rd.getSrcLP().getLP()), rd.getItemKey(),
rd.getReceiveDate(), null, rd.getReceivedQuantity(), null,
srcInv == null ? "" : srcInv.getStatus(), srcInv == null ? 0L : srcInv.getId(), null,
asn.getBillType(), 0, rd.getBarCode(), rd.getLocation(),asn.getSourceType());
asn.getBillType(), 0, rd.getBarCode(), rd.getLocation(),asn.getSourceType(),null);
//上报SAP
if(!asn.getCode().substring(0, 2).equals("RP")
&&(asn.getSourceType()!=null&&!asn.getSourceType().equals("313"))
@ -2599,15 +2599,14 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
}
px_sql += " ,substring(l.name,7,2) asc,substring(l.name,4,2) asc";
List<LocationStorage> ls =new ArrayList<LocationStorage>();
//查询深浅都是空闲,对应的深位。
String hql1="";
//查询深浅都是空
hql1=sql+ " and l.relevanceCode not in("+sql5+") ";
ls = this.commonDao.findByQuery(hql1 + px_sql);
if (ls.size() <= 15) {
if (ls.size() <= 20) {
throw new BusinessException("无合适的存放位");
} else {
return ls.get(0);
@ -2627,11 +2626,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
// 释放
LocationStorage l1 = queryLsFor7(t.getFromCellCode(), "");//起点
LocationStorage l2 = queryLsFor7(t.getToCellCode(), "");//终点
// if(t.getStatus().equals(STATUS.ATCALL)){
// if(t.getType().equals(LibraryTaskType.rkt)){
// s.setEnabled(Boolean.TRUE);
// }
// }
//已完成
if (t.getStatus().equals(STATUS.RECEIVED)) {
flag=false;
@ -2641,15 +2636,9 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
if (t.getStatus().equals(STATUS.ATPICK)) {
//出库,再次发送变成已完成
if (t.getType().equals(LibraryTaskType.ck)) {
t.setStatus(STATUS.RECEIVED);
t.setStatus(STATUS.RECEIVED);//完成
t.setFinishDate(new Date());
this.commonDao.store(t);
/*List<Stock> stocks = commonDao.findByQuery(" from Stock stock where stock.LP='"+t.getBarcode()+"'");
if (stocks.size()>0) {
Stock stock=stocks.get(0);
stock.setLocationStorage(null);
this.commonDao.store(stock);
}*/
flag=false;
}
}
@ -2725,7 +2714,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
if (l2!=null) {
l2.setStatus(WarehouseAreaStatus.OCCUPY);
s.setAgvFlag(true);//是否AGV仓库
s.setEnabled(false);//是否失效
// s.setEnabled(false);//是否失效
s.setLocationStorage(l2);
this.commonDao.store(l2);
List<LocationStorage> lsq12 = this.commonDao
@ -2762,6 +2751,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
}
}
if (t.getType().equals(LibraryTaskType.ck)||t.getType().equals(LibraryTaskType.ckt)) {
if (l1!=null) {
l1.setStatus(WarehouseAreaStatus.FREE);
@ -2796,6 +2786,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
s.setAgvFlag(true);
}
this.commonDao.store(s);
//跟新未下发出库任务的起点
List<LibraryTask> lists=commonDao.findByQuery(" from LibraryTask l where l.barcode='"+s.getLP()+"'"
+ " and l.status='NONCHECKED' and l.type in('3','2') ");
@ -2804,54 +2795,8 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
commonDao.store(tl);
}
/*
if (t.getRelationCode() == null) {/*
if (t.getType().equals(LibraryTaskType.ck)||t.getType().equals(LibraryTaskType.ckt)) {
// 释放点位状态,如果是深位,则锁定的浅位也需要释放状态
releaseLsForCk(t);
t.setStatus(STATUS.ATPICK);
this.commonDao.store(t);
}
} else {
List<LibraryTask> ts = this.commonDao.findByQuery("from LibraryTask t where t.relationCode='"
+ t.getRelationCode() + "' and t.status='OPEN'");
if (ts.size() <= 0) {
List<LibraryTask> tss = this.commonDao.findByQuery("from LibraryTask t where t.relationCode='"
+ t.getRelationCode() + "' order by seq asc");
for (LibraryTask lt : tss) {
if (lt.getType().equals(LibraryTaskType.ck)||t.getType().equals(LibraryTaskType.ckt)) {
lt.setStatus(STATUS.ATPICK);
lt.setMes("已到站");
this.commonDao.store(lt);
interfaceReqManager.receiveLEDinfo(lt);
}
/*
if (lt.getType().equals(LibraryTaskType.yk)) {
// 1释放2占用
l1.setStatus(WarehouseAreaStatus.FREE);
this.commonDao.store(l1);
l2.setStatus(WarehouseAreaStatus.OCCUPY);
this.commonDao.store(l2);
} else if (lt.getType().equals(LibraryTaskType.ck)||t.getType().equals(LibraryTaskType.ckt)) {
lt.setStatus(STATUS.ATPICK);
this.commonDao.store(lt);
}
}
} else {
// 没全部释放的时候
}
}*/
}
// t.setStatus(STATUS.RECEIVED);
// t.setFinishDate(new Date());
// this.commonDao.store(t);
// //下发托盘搬运任务
// executeLibraryTask(s, null, TranType.yt_in,"1011-1");
}
public void sendLibraryTask() {
@ -4159,9 +4104,8 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
// hql1=sql+" and l.relevanceCode in ( "+sql1+") and l.sqType=2 and l.relevanceCode not in("+sql5+")";
hql1=sql+" and l.relevanceCode not in("+sql5+")";
ls = this.commonDao.findByQuery(hql1 + px_sql);
if (ls.size() <= 10) {
if (ls.size() <= 5) {
throw new BusinessException("不存在合适的库位");
} else {
return ls.get(0);

View File

@ -2408,7 +2408,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
// 写库存日志
inventoryManager.addInventoryLog(InventoryLogType.CONVERT_PACKAGEUNIT, 1, log.getSOI(), log.getDstLoc(),
log.getDstLPCode(), ik, log.getStorageDate(), log.getSOI(), movedQuantity, null,
log.getInventoryStatus(), log.getId(), "出库退料", null, 0, inventory.getBarCode(), null,null);
log.getInventoryStatus(), log.getId(), "出库退料", null, 0, inventory.getBarCode(),
null,null,null);
} else {
throw new BusinessException("moveDoc.pickBackLoc.none");
}
@ -3729,7 +3730,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.MOVE, 1, inventory.getSOI(), loc, "", itemKey,
inventory.getStorageDate(), inventory.getSOI(), picked_quantity, null, inventory.getStatus(),
inventory.getId(), "部分移库", null, 0, inventory.getBarCode(), null,null);
inventory.getId(), "部分移库", null, 0, inventory.getBarCode(), null,null,null);
commonDao.store(itemKey);
return mes;
}
@ -4274,8 +4275,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, task.getBillCode(), dstLoc, dstLP==null?"":dstLP.getLP(),
task.getItemKey(), srcInv.getStorageDate(), srcInv.getSOI(), pickedQuantity, null,
srcInv.getStatus(), srcInv.getId(), "拣货", pt.getBillType(), workerId, srcInv.getBarCode(),
task.getSrcLoc(),pt.getSourceType());
task.getSrcLoc(),pt.getSourceType(),ptd.getLocType());
} else {
Inventory newInventory = EntityFactory.getEntity(Inventory.class);
@ -4361,7 +4361,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, task.getBillCode(), dstLoc, dstLP==null?"":dstLP.getLP(),
task.getItemKey(), task.getStorageDate(), task.getSOI(),
pickedQuantity, null, newInventory.getStatus(), task.getId(), "拣货",
pt.getBillType(), workerId, task.getBarCode(), srcInv.getLocation(),pt.getSourceType());
pt.getBillType(), workerId, task.getBarCode(), srcInv.getLocation(),pt.getSourceType(),ptd.getLocType());
}
}
// 刷新出库明细上的拣货数量
@ -4772,7 +4772,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(),
inv.getLocation(), null, itemKey, inv.getStorageDate(), inv.getSOI(),
tl.getShipQuantity(), null, inv.getStatus(), inv.getId(), "发运", null, userId,
inv.getBarCode(), null,null);
inv.getBarCode(), null,null,null);
// 扣减库存
inv.setQuantity(inv.getQuantity() - tl.getShipQuantity());
inv.setVersion(inv.getVersion());
@ -4872,7 +4872,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(),
inv.getLocation(), null, itemKey, inv.getStorageDate(), inv.getSOI(),
tl.getShipQuantity(), null, inv.getStatus(), inv.getId(), "发运", null, userId,
inv.getBarCode(), null,null);
inv.getBarCode(), null,null,null);
// 扣减库存
inv.setQuantity(inv.getQuantity() - tl.getShipQuantity());
inv.setVersion(inv.getVersion());
@ -4948,7 +4948,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
// 写入库存日期
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(), inv.getLocation(),
null, itemKey, inv.getStorageDate(), inv.getSOI(), tl.getShipQuantity(), null,
inv.getStatus(), inv.getId(), "发运", null, userId, inv.getBarCode(), null,null);
inv.getStatus(), inv.getId(), "发运", null, userId, inv.getBarCode(), null,null,null);
// 扣减库存
inv.setQuantity(inv.getQuantity() - tl.getShipQuantity());
inv.setVersion(inv.getVersion());
@ -7130,8 +7130,10 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
public void createSeedWallTask1(String lsCode) {
synchronized ("a") {
//查询货架区、料箱区,未绑定分拨墙的数据
List<Object> list = commonDao.findByQuery("select t.billCode from " + " Task t where t.agvStatus=1 and "
+ " t.planQuantity>t.movedQuantityMU " + " group by t.billCode" + " order by t.billCode ");
+ " t.planQuantity>t.movedQuantityMU and t.srcLoc.zone.id in(1765,1763) "
+ " group by t.billCode" + " order by t.billCode ");
if (list.size() > 0) {
StringBuffer sBuffer = new StringBuffer();
sBuffer.append("select ls.NAME,COUNT(*) from seed_wall sw \r\n"
@ -7936,7 +7938,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(), dstLoc, null,
srcInv.getItemKey(), srcInv.getStorageDate(), srcInv.getSOI(), task.getPlanQuantity(), null,
srcInv.getStatus(), srcInv.getId(), "拣选", pt.getBillType(), workerId, srcInv.getBarCode(),
task.getSrcLoc(),pt.getSourceType());
task.getSrcLoc(),pt.getSourceType(),ptd.getLocType());
} else {
Inventory newInventory = EntityFactory.getEntity(Inventory.class);
@ -7974,7 +7976,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(), dstLoc, null,
newInventory.getItemKey(), newInventory.getStorageDate(), newInventory.getSOI(),
task.getPlanQuantity(), null, newInventory.getStatus(), newInventory.getId(), "拣货",
pt.getBillType(), workerId, newInventory.getBarCode(), srcInv.getLocation(),pt.getSourceType());
pt.getBillType(), workerId, newInventory.getBarCode(), srcInv.getLocation(),
pt.getSourceType(),ptd.getLocType());
}
}
@ -8057,7 +8060,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(), dstLoc, null,
srcInv.getItemKey(), srcInv.getStorageDate(), srcInv.getSOI(), task.getPlanQuantity(), null,
srcInv.getStatus(), srcInv.getId(), "拣选", pt.getBillType(), workerId, srcInv.getBarCode(),
task.getSrcLoc(),pt.getSourceType());
task.getSrcLoc(),pt.getSourceType(),ptd.getLocType());
} else {
Inventory newInventory = EntityFactory.getEntity(Inventory.class);
@ -8095,7 +8098,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, pt.getCode(), dstLoc, null,
newInventory.getItemKey(), newInventory.getStorageDate(), newInventory.getSOI(),
task.getPlanQuantity(), null, newInventory.getStatus(), newInventory.getId(), "拣货",
pt.getBillType(), workerId, newInventory.getBarCode(), srcInv.getLocation(),pt.getSourceType());
pt.getBillType(), workerId, newInventory.getBarCode(), srcInv.getLocation(),
pt.getSourceType(),ptd.getLocType());
}
}
// 刷新出库明细上的拣货数量
@ -8343,7 +8347,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.HAND_ORDER, 1, t.getBillCode(),loc , null,
i.getItemKey(), i.getStorageDate(), i.getSOI(), i.getQuantity(), null,
i.getStatus(), i.getId(), "交单", t.getPickTicketDetail().getPickTicket().getBillType(), w.getId(), i.getBarCode(),
t.getSrcLoc(),t.getPickTicketDetail().getPickTicket().getSourceType());
t.getSrcLoc(),t.getPickTicketDetail().getPickTicket().getSourceType(),
t.getPickTicketDetail().getLocType());
commonDao.delete(i);
}
t.setInventoryStatus("交单完成");
@ -8396,7 +8401,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
t.getDstLP()==null?null: t.getDstLP().getLP(),
inv.getItemKey(), inv.getStorageDate(), inv.getSOI(), t.getPlanQuantity(), null,
inv.getStatus(), inv.getId(), "交单", t.getPickTicketDetail().getPickTicket().getBillType(),
0L, inv.getBarCode(),t.getDstLoc(),t.getPickTicketDetail().getPickTicket().getSourceType());
0L, inv.getBarCode(),t.getDstLoc(),
t.getPickTicketDetail().getPickTicket().getSourceType(),null);
commonDao.delete(inv);
}
// t.setPopular(1);
@ -8505,16 +8511,17 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
for(Inventory inv:invs) {
invqty1=inv.getQueuedQuantity();//占用数量
invqty2=inv.getQuantity();//库存数量
ItemKey itemkey1=inv.getItemKey();
if(invqty2<=t_qty) {
inv.setQueuedQuantity(0);
inv.setItemKey(itemkey);
commonDao.store(inv);
t_qty=t_qty-t_qty;
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, t.getBillCode(), t.getDstLoc(), null,
inv.getItemKey(), inv.getStorageDate(), inv.getSOI(), t.getPlanQuantity(), null,
itemkey1, inv.getStorageDate(), inv.getSOI(), t.getPlanQuantity(), null,
inv.getStatus(), inv.getId(), "转库", t.getPickTicketDetail().getPickTicket().getBillType(),
0L, inv.getBarCode(),t.getSrcLoc(),t.getPickTicketDetail().getPickTicket().getSourceType());
0L, inv.getBarCode(),t.getSrcLoc(),
t.getPickTicketDetail().getPickTicket().getSourceType(),t.getPickTicketDetail().getLocType());
}else {
if(invqty2>t_qty) {
@ -8533,12 +8540,58 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
newInventory.setWarehouseArea(inv.getWarehouseArea());
newInventory.setBarCode(t.getBarCode());
newInventory.setStatuss(inv.getStatuss());
String sql1 = " from Inventory inv where inv.itemKey.id=" + itemkey.getId()
+ " and inv.location.id=" + inv.getLocation().getId();
if (t.getBarCode() != null && t.getBarCode().length() > 0) {
sql += " and inv.barCode='" + t.getBarCode() + "'";
}
List<Inventory> listinvs = commonDao.findByQuery(sql1);
String hql = " from Inventory inv where inv.location.id=" + inv.getLocation().getId()
+ " and inv.quantity>0 and inv.itemKey.item.id="+itemkey.getItem().getId();
if(itemkey.getLotInfo().getPropC1()!=null&&itemkey.getLotInfo().getPropC1().length()>0) {
hql += " AND inv.itemKey.lotInfo.propC1='" + itemkey.getLotInfo().getPropC1() + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propC1 is null ";
}
if(itemkey.getLotInfo().getPropC2()!=null&&itemkey.getLotInfo().getPropC2().length()>0) {
hql += " AND inv.itemKey.lotInfo.propC2='" + itemkey.getLotInfo().getPropC2() + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propC2 is null ";
}
if(itemkey.getLotInfo().getPropC3()!=null&&itemkey.getLotInfo().getPropC3().length()>0) {
hql += " AND inv.itemKey.lotInfo.propC3='" + itemkey.getLotInfo().getPropC3() + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propC3 is null ";
}
if(itemkey.getLotInfo().getPropC5()!=null&&itemkey.getLotInfo().getPropC5().length()>0) {
hql += " AND inv.itemKey.lotInfo.propC5='" + itemkey.getLotInfo().getPropC5() + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propC5 is null ";
}
if(itemkey.getLotInfo().getPropC9()!=null&&itemkey.getLotInfo().getPropC9().length()>0) {
hql += " AND inv.itemKey.lotInfo.propC9='" + itemkey.getLotInfo().getPropC9() + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propC9 is null ";
}
if (t.getBarCode() != null && !t.getBarCode().equals("")) {
hql += " AND inv.barCode='" + t.getBarCode() + "' ";
}
if (inv.getStatuss() != null && !inv.getStatuss().equals("")) {
hql += " AND inv.statuss='" + inv.getStatuss() + "' ";
}else {
hql += " AND (inv.statuss='' or inv.statuss is null)";
}
if(t.getItemKey().getLotInfo().getPropD2()!=null) {
SimpleDateFormat ymd = new SimpleDateFormat("yyyy-MM-dd");
hql += " AND CONVERT(varchar(100), inv.itemKey.lotInfo.propD2, 23)='" +ymd.format(itemkey.getLotInfo().getPropD2()) + "' ";
}else {
hql += " AND inv.itemKey.lotInfo.propD2 is null ";
}
List<Inventory> listinvs = commonDao.findByQuery(hql);
// String sql1 = " from Inventory inv where inv.itemKey.id=" + itemkey.getId()
// + " and inv.location.id=" + inv.getLocation().getId();
//
// if (t.getBarCode() != null && t.getBarCode().length() > 0) {
// sql += " and inv.barCode='" + t.getBarCode() + "'";
// }
// List<Inventory> listinvs = commonDao.findByQuery(sql1);
if (listinvs.size() > 0) {
newInventory = listinvs.get(0);
newInventory.setQuantity(newInventory.getQuantity() + t_qty);
@ -8564,7 +8617,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, t.getBillCode(), t.getDstLoc(), null,
inv.getItemKey(), inv.getStorageDate(), inv.getSOI(), t.getPlanQuantity(), null,
inv.getStatus(), inv.getId(), "转库", t.getPickTicketDetail().getPickTicket().getBillType(),
0L, inv.getBarCode(),t.getSrcLoc(),t.getPickTicketDetail().getPickTicket().getSourceType());
0L, inv.getBarCode(),t.getSrcLoc(),t.getPickTicketDetail().getPickTicket().getSourceType(),
t.getPickTicketDetail().getLocType());
t_qty=0;
}
}
@ -8843,7 +8897,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, soi, loc, lp,
t.getItemKey(), t.getStorageDate(), t.getSOI(),
t.getQuantity(), null, t.getStatus(), t.getId(), "合单移动",
bt, workerId, t.getBarCode(), l,"");
bt, workerId, t.getBarCode(), l,"",null);
}
}
@ -8893,7 +8947,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, soi, loc, null,
t.getItemKey(), t.getStorageDate(), t.getSOI(),
t.getQuantity(), null, t.getStatus(), t.getId(), "合单移动",
bt, workerId, t.getBarCode(), l,"");
bt, workerId, t.getBarCode(), l,"",null);
}
}
@ -9078,7 +9132,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
}
commonDao.store(inv);
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, t.getBillCode(), dstLoc, lp, ik,
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "合单",pt.getBillType() ,userId,inv.getBarCode(),srcLoc,pt.getSourceType());
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "合单",
pt.getBillType() ,userId,inv.getBarCode(),srcLoc,pt.getSourceType(),null);
}
}
@ -9309,7 +9364,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
for(Inventory inv:invs) {
//库存日志
inventoryManager.addInventoryLog(InventoryLogType.HAND_ORDER, 1, inv.getSOI(), dstLoc, stockCode, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,userId,inv.getBarCode(),inv.getLocation(),"");
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,userId,inv.getBarCode(),
inv.getLocation(),"",null);
//删除库存拣货
inventoryManager.deleteInv(inv);
}
@ -9363,7 +9419,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
for(Inventory inv:invs) {
//库存日志
inventoryManager.addInventoryLog(InventoryLogType.HAND_ORDER, 1, inv.getSOI(), dstLoc, "", inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,userId,inv.getBarCode(),inv.getLocation(),"");
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,userId,
inv.getBarCode(),inv.getLocation(),"",null);
//删除库存拣货
inventoryManager.deleteInv(inv);
}
@ -9410,7 +9467,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
PickTicket pt=commonDao.load(PickTicket.class, id);
List<Long> Tasks2=commonDao.findByQuery("select t.id from Task t where t.pickTicketDetail.pickTicket.id="+pt.getId()+" and t.planQuantity>0 ");
List<Long> Taskss2=commonDao.findByQuery("select t.id from Task t where t.pickTicketDetail.pickTicket.id="+pt.getId()+" "
+ "and t.inventoryStatus='交单完成' and t.planQuantity>0 and t.planQuantity<=t.movedQuantityMU ");
+ " and t.dstLoc.zone.id=1787 and t.planQuantity>0 and t.planQuantity<=t.movedQuantityMU ");
if(Tasks2.size()==Taskss2.size()){
pt.setStatus(PickTicketStatus.JIAODAN);
commonDao.store(pt);
@ -9735,7 +9792,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
}
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, t.getBillCode(), mbloc, lp, ik,
t.getStorageDate(), pt.getCode(), t.getPlanQuantity(), null, taskStatus, t.getId(), "合单",pt.getBillType() ,
userId,t.getBarCode(),srcLoc,pt.getSourceType());
userId,t.getBarCode(),srcLoc,pt.getSourceType(),null);
}
//是否交单
@ -10224,7 +10281,8 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
for(Inventory inv:invs) {
//库存日志
inventoryManager.addInventoryLog(InventoryLogType.HAND_ORDER, 1, inv.getSOI(), dstLoc, stockCode, inv.getItemKey(),
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,worker.getId(),inv.getBarCode(),inv.getLocation(),"");
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "交单", null,worker.getId(),
inv.getBarCode(),inv.getLocation(),"",null);
//删除库存拣货
inventoryManager.deleteInv(inv);
}
@ -10316,7 +10374,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
t.getDstLP()==null?null: t.getDstLP().getLP(),
inv.getItemKey(), inv.getStorageDate(), inv.getSOI(), t.getPlanQuantity(), null,
inv.getStatus(), inv.getId(), "交单", t.getPickTicketDetail().getPickTicket().getBillType(),
0L, inv.getBarCode(),t.getDstLoc(),t.getPickTicketDetail().getPickTicket().getSourceType());
0L, inv.getBarCode(),t.getDstLoc(),t.getPickTicketDetail().getPickTicket().getSourceType(),null);
commonDao.delete(inv);
}
// t.setPopular(1);

View File

@ -3722,7 +3722,8 @@ public class DefaultWaveDocManager extends DefaultBaseManager implements
inventory=Inventorys.get(0);
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, t.getBillCode(), loc, null, task.getItemKey(),
inventory.getStorageDate(), inventory.getSOI(), inventory.getQuantity(), null, inventory.getStatus(), inventory.getId(),
"交单",pt.getBillType() ,UserHolder.getUser().getId(),inventory.getBarCode(),task.getDstLoc(),pt.getSourceType());
"交单",pt.getBillType() ,UserHolder.getUser().getId(),inventory.getBarCode(),task.getDstLoc(),
pt.getSourceType(),null);
commonDao.delete(inventory);
Location srcLoc=this.load(Location.class, t.getDstLoc().getId());//交单库位
// inventoryManager.manualMove(inventory.getId(), loc.getId(), false, task.getDstLP().getLP(), inventory.getQuantity(), 0L);
@ -3747,7 +3748,7 @@ public class DefaultWaveDocManager extends DefaultBaseManager implements
inventory=Inventorys.get(0);
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, task.getBillCode(), loc, null, task.getItemKey(),
inventory.getStorageDate(), inventory.getSOI(), inventory.getQuantity(), null, inventory.getStatus(), inventory.getId(),
"交单",pt.getBillType() ,UserHolder.getUser().getId(),inventory.getBarCode(),task.getDstLoc(),pt.getSourceType());
"交单",pt.getBillType() ,UserHolder.getUser().getId(),inventory.getBarCode(),task.getDstLoc(),pt.getSourceType(),null);
commonDao.delete(inventory);
// inventoryManager.manualMove(inventory.getId(), loc.getId(), false, task.getDstLP().getLP(), inventory.getQuantity(), 0L);
task.setDstLoc(loc);

View File

@ -2495,7 +2495,7 @@ public class ASNReceiveServlet extends HttpServlet {
}
inventoryManager.addInventoryLog(InventoryLogType.PROCESS_UP, 1, t.getBillCode(), dstLoc, lp, ik,
inv.getStorageDate(), inv.getSOI(), inv.getQuantity(), null, inv.getStatus(), inv.getId(), "合单移动",
pt.getBillType() ,userId,inv.getBarCode(),srcLoc,pt.getSourceType());
pt.getBillType() ,userId,inv.getBarCode(),srcLoc,pt.getSourceType(),null);
status="1";
msg="操作成功";
}
@ -3052,7 +3052,9 @@ public class ASNReceiveServlet extends HttpServlet {
Location loc=commonDao.load(Location.class, tasks.getSrcLoc().getId());
InventoryManager inventoryManager = (InventoryManager) ac.getBean("inventoryManager");
inventoryManager.addInventoryLog(InventoryLogType.COMPANY_TRANS_OUT, 1, tasks.getBillCode(), loc, null, itemKey,
new Date(), null, tasks.getPlanQuantity(), null, tasks.getInventoryStatus(), tasks.getId(), content,pt.getBillType() ,workerId,tasks.getBarCode(),loc,pt.getSourceType());
new Date(), null, tasks.getPlanQuantity(), null, tasks.getInventoryStatus(),
tasks.getId(), content,pt.getBillType() ,workerId,tasks.getBarCode(),
loc,pt.getSourceType(),ptd.getLocType());
status="1";
}else{
msg="taskId参数错误或为null";

View File

@ -122,7 +122,6 @@ public class InventoryServlet extends HttpServlet{
resultObject.put("returnMsg","成功");
resultOutput=resultObject.toString();
}
}
}
}else{

View File

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<pages>
<editPage id="editPlanItemDetailPage" title="序列号维护"
entityClass="com.dev.swms.server.model.base.MaterialFactory" width="200" height="260">
<inputUIs>
<hidden id="md.id" reserve="true" />
<text id="item.planCode" title="工厂" row="1" col="1" readOnly="true"
required="false" reserve="false" forceOverride="false" inVisible="false"
length="20" trimSpace="true" isPrecision="true" />
<checkbox id="md.beMarkWeight" title="是否序列管理" row="2" col="1" defaultValue="false" span="1" readOnly="false" required="false" reserve="false" forceOverride="true" inVisible="false"/>
</inputUIs>
<buttons>
<commit id="save" title="save" enableType="none">
<mappings>
<mapping id="mf" className="com.dev.swms.server.model.base.MaterialFactory" />
</mappings>
<actions>
<action managerName="itemManager" methodName="storeMaterialFactory"
parameter="mf" />
</actions>
<forwards>
<forward name="refreshParent" newEnabled="true"
editEnabled="true" />
<forward name="refreshWindow" newEnabled="true"
editEnabled="true" />
</forwards>
</commit>
</buttons>
</editPage>
</pages>

View File

@ -158,11 +158,9 @@
</columns>
<buttons>
<!-- <popup id="modify" title="edit" enableType="single" invisible="false" -->
<!-- containId="true" pageId="editItemDetailPage"> -->
<!-- </popup> -->
<popup id="modifyPlancode" title="调整" enableType="single" invisible="false"
containId="true" pageId="editPlanItemDetailPage">
</popup>
</buttons>
</maintainPage>
</pages>

View File

@ -33,6 +33,7 @@
w.description,
w.disabled,
w.equipment,
w.user.name,
w.describe
from Worker w
left join w.user user
@ -64,6 +65,8 @@
formatParam="disabled" />
<column id="w.equipment" title="手持设备" visible="true"
horizonAlign="center" verticalAlign="middle" />
<column id="w.user.name" title="系统账号" visible="true"
horizonAlign="center" verticalAlign="middle" />
<column id="w.describe" title="备注" visible="true"
horizonAlign="center" verticalAlign="middle" />
</columns>

View File

@ -134,6 +134,7 @@
inventoryLog.srcLoc.zone.code,
inventoryLog.endRegion,
inventoryLog.strbill1,
inventoryLog.strbill2,
inventoryLog.LP,
inventoryLog.status
FROM InventoryLog inventoryLog
@ -207,9 +208,10 @@
title="库区" visible="true" horizonAlign="center" />
<column id="inventoryLog.endRegion" width="80"
title="工作站" visible="true" horizonAlign="center" />
<column id="inventoryLog.strbill1" width="80"
<column id="inventoryLog.strbill1" width="60"
title="SAP移动类型" visible="true" horizonAlign="center" />
<column id="inventoryLog.strbill2" width="80"
title="接收LOC" visible="true" horizonAlign="center" />
<column id="inventoryLog.LP" width="80"
title="容器" visible="true" horizonAlign="center" />
<column id="inventoryLog.status" width="80"

View File

@ -121,7 +121,9 @@
inventory.storageDate,
inventory.invDes,
inventory.propC7,
inventory.lock
inventory.lock,
inventory.item.id,
inventory.location.id
FROM InventoryView inventory
WHERE 1=1
and inventory.quantity>0 and inventory.beSAPItem=true

View File

@ -15,7 +15,8 @@
<hidden id="inventory.propC5" reserve="false" />
<hidden id="inventory.propC9" reserve="false" />
<hidden id="inventory.statuss" reserve="false" />
<hidden id="inventory.item.id" reserve="false" />
<hidden id="inventory.location.id" reserve="false" />
</inputUIs>
<buttons>
@ -50,6 +51,8 @@
LEFT JOIN inventory.warehouseArea
WHERE 1=1
and inventory.quantity!=0
/~inventory.item.id: AND item.id = {inventory.item.id}~/
/~inventory.location.id: AND loc.id = {inventory.location.id}~/
/~inventory.itemCode: AND item.code = {inventory.itemCode}~/
/~inventory.locCode: AND loc.code = {inventory.locCode}~/
/~inventory.propC1: AND inventory.itemKey.lotInfo.propC1 = {inventory.propC1}~/

View File

@ -0,0 +1,73 @@
<?xml version="1.0" encoding="UTF-8"?>
<pages>
<maintainPage id="maintainOtherPickTicketPage" title="转库单模板"
autoQuery="false" width="950" height="550">
<search>
<inputUIs>
</inputUIs>
</search>
<datasource type="hql"><![CDATA[ select
item.code,
item.name,
item.CAname,
item.packNumber,
item.suggest,
item.weight,
item.length,
item.width,
item.height,
item.volume,
item.unit,
item.warehouseArea.name,
item.goodType,
item.shipRules,
item.validPeriod,
item.alertLeadingDays,
item.singleItem,
item.brand,
item.beMarkWeight,
item.isBOM,
item.beWeight,
item.beInv,
item.beSAPItem,
item.saleTime
from Item item
left join item.warehouseArea warehouseArea
where item.id=1
]]></datasource>
<columns>
<column id="item.code" title="预留号" width="50" visible="true"
horizonAlign="center" />
<column id="item.name" title="项号" width="40" visible="true"
horizonAlign="center" />
<column id="item.CAname" title="转库类型" visible="true"
horizonAlign="center" />
<column id="item.packNumber" title="需求日期YYYY-MM-DD" visible="true"
horizonAlign="center" />
<column id="item.weight" title="料号" visible="true" width="40"
horizonAlign="center" />
<column id="item.suggest" title="数量" visible="true" width="70"
horizonAlign="center" />
<column id="item.length" title="工厂" visible="true" width="40"
horizonAlign="center" />
<column id="item.width" title="LOC" visible="true" width="40"
horizonAlign="center" />
<column id="item.unit" title="接收工厂" visible="true" width="70"
horizonAlign="center" />
<column id="item.zonce" title="接收LOC" visible="true" width="70"
horizonAlign="center" />
<column id="item.singleItem" title="序列号" visible="true" width="60"
horizonAlign="center" />
<column id="item.brand" title="特殊标记" visible="true" width="70"
horizonAlign="center" />
<column id="item.validPeriod" title="供应商" visible="true" width="60"
horizonAlign="center" />
</columns>
<buttons>
</buttons>
</maintainPage>
</pages>

View File

@ -46,6 +46,7 @@
pickTicket.orderDate,
pickTicket.status,
pickTicket.billType.name,
pickTicket.deliveryMode,
pickTicket.packageQuantity,
pickTicket.orderQuantity,
pickTicket.allocatedQuantity,
@ -58,7 +59,7 @@
pickTicket.jiaodanDate,
pickTicket.workerName1,
pickTicket.workerName4,
pickTicket.deliveryMode,
pickTicket.shipmentMethod,
pickTicket.sourceId,
pickTicket.userName
@ -97,6 +98,8 @@
formatParam="PickTicketStatus" />
<column id="pickTicket.billType.name" width="80" title="billType"
visible="true" horizonAlign="center" verticalAlign="middle" />
<column id="pickTicket.deliveryMode" width="140" title="receiver"
visible="true" horizonAlign="center" />
<column id="pickTicket.totals" width="80" title="任务行数"
visible="true" horizonAlign="center" verticalAlign="middle" />
<column id="pickTicket.orderQuantity" width="70"
@ -127,8 +130,7 @@
visible="true" horizonAlign="center" />
<column id="pickTicket.workerName4" width="140" title="申请人"
visible="true" horizonAlign="center" />
<column id="pickTicket.deliveryMode" width="140" title="receiver"
visible="true" horizonAlign="center" />
<column id="pickTicket.shipmentMethod" width="140" title="交接位置"
visible="true" horizonAlign="center" />
<column id="pickTicket.sourceId" width="150" title="SAP接口号"
@ -336,6 +338,9 @@
</popup>
<popup id="SHASO2" title="导入转库单"
enableType="none" invisible="false" containId="true" pageId="editImportOutOrderPage" />
<popup id="zhuanKuDanMuBan" title="转库单模板"
enableType="none" invisible="false" containId="true" pageId="maintainOtherPickTicketPage" />
<popup id="SHAS21123O2" title="导入其它出库单"
enableType="none" invisible="false" containId="true" pageId="editImportOtherOrderDetailPag" />
</buttons>

View File

@ -187,9 +187,7 @@
agv.createTime as agv_createTime_2,
agv.dateTime2,
agv.dateTime3,
agv.jobPriorityType,
t.old_Gzz,
t.old_Zrw,
agv.agvStartSlotCode,
z.name as z_name,
pt.sourceType,
bt.name as bt_name,
@ -330,9 +328,7 @@ left OUTER join WORKER w4 on w4.id=t.WORKER4_ID
<column id="agv.createTimel3134" title="AGV生成时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.dateTime22314" title="agv开始搬运时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.dateTime3314" title="到输送线时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.jobPriorityType" title="AGV等级" width="80" visible="false" horizonAlign="center" />
<column id="t.oldGzz" title="新工作站" width="80" visible="false" horizonAlign="center" />
<column id="t.oldZrw" title="新子任务" width="80" visible="false" horizonAlign="center" />
<column id="agv.agvStartSlotCode" title="取箱位置" width="120" visible="false" horizonAlign="center" />
<column id="szone.name" title="拣货库区" visible="true" horizonAlign="center" />
<column id="pickTicket.sourceType" title="移动类型" width="100" visible="true" horizonAlign="center" />
<column id="billType.name" title="单据类型" width="100" visible="true" horizonAlign="center" />

View File

@ -190,9 +190,7 @@
agv.createTime,
agv.dateTime2,
agv.dateTime3,
agv.jobPriorityType,
t.oldGzz,
t.oldZrw,
agv.agvStartSlotCode,
szone.name,
pickTicket.sourceType,
billType.name,
@ -337,9 +335,8 @@
<column id="agv.createTimel3134" title="AGV生成时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.dateTime22314" title="agv开始搬运时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.dateTime3314" title="到输送线时间" visible="false" horizonAlign="center" format="dateTiemFormatter" />
<column id="agv.jobPriorityType" title="AGV等级" width="80" visible="false" horizonAlign="center" />
<column id="t.oldGzz" title="新工作站" width="80" visible="false" horizonAlign="center" />
<column id="t.oldZrw" title="新子任务" width="80" visible="false" horizonAlign="center" />
<column id="agv.agvStartSlotCode" title="取箱位置" width="120" visible="false" horizonAlign="center" />
<column id="szone.name" title="拣货库区" visible="true" horizonAlign="center" />
<column id="pickTicket.sourceType" title="移动类型" width="100" visible="true" horizonAlign="center" />
<column id="billType.name" title="单据类型" width="100" visible="true" horizonAlign="center" />