优化调整
parent
0d74ded00e
commit
f88e0eed5c
|
|
@ -188,7 +188,15 @@ public class Item extends Entity {
|
|||
private Number largeHeight;
|
||||
|
||||
|
||||
public WarehouseArea getDefaultWarehouseArea() {
|
||||
public boolean isBeWholeLine() {
|
||||
return beWholeLine;
|
||||
}
|
||||
|
||||
public void setBeWholeLine(boolean beWholeLine) {
|
||||
this.beWholeLine = beWholeLine;
|
||||
}
|
||||
|
||||
public WarehouseArea getDefaultWarehouseArea() {
|
||||
return defaultWarehouseArea;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ public class LotInfo extends DomainModel implements ApplicationContextAware{
|
|||
private String propLC2;//成品标记
|
||||
private String propLC3;//元值
|
||||
private String propLC4;//币种
|
||||
|
||||
private static ApplicationContext ac;
|
||||
private CommonDao commonDao;
|
||||
|
||||
|
|
|
|||
|
|
@ -50,78 +50,78 @@ public class WorkOrderAllocationInfo extends Entity{
|
|||
*/
|
||||
private Date allocationDate;
|
||||
|
||||
public String getWorkOrderNumber() {
|
||||
return workOrderNumber;
|
||||
}
|
||||
|
||||
public void setWorkOrderNumber(String workOrderNumber) {
|
||||
this.workOrderNumber = workOrderNumber;
|
||||
}
|
||||
|
||||
public int getLineNumber() {
|
||||
return lineNumber;
|
||||
}
|
||||
|
||||
public void setLineNumber(int lineNumber) {
|
||||
this.lineNumber = lineNumber;
|
||||
}
|
||||
|
||||
public String getMaterialNumber() {
|
||||
return materialNumber;
|
||||
}
|
||||
|
||||
public void setMaterialNumber(String materialNumber) {
|
||||
this.materialNumber = materialNumber;
|
||||
}
|
||||
|
||||
public int getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(int quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public String getRemarks() {
|
||||
return remarks;
|
||||
}
|
||||
|
||||
public void setRemarks(String remarks) {
|
||||
this.remarks = remarks;
|
||||
}
|
||||
|
||||
public String getLocationNumber() {
|
||||
return locationNumber;
|
||||
}
|
||||
|
||||
public void setLocationNumber(String locationNumber) {
|
||||
this.locationNumber = locationNumber;
|
||||
}
|
||||
|
||||
public String getFactory() {
|
||||
return factory;
|
||||
}
|
||||
|
||||
public void setFactory(String factory) {
|
||||
this.factory = factory;
|
||||
}
|
||||
|
||||
public String getLoc() {
|
||||
return loc;
|
||||
}
|
||||
|
||||
public void setLoc(String loc) {
|
||||
this.loc = loc;
|
||||
}
|
||||
|
||||
public Date getAllocationDate() {
|
||||
return allocationDate;
|
||||
}
|
||||
|
||||
public void setAllocationDate(Date allocationDate) {
|
||||
this.allocationDate = allocationDate;
|
||||
}
|
||||
|
||||
// Getter 和 Setter 方法
|
||||
|
||||
|
||||
public String getWorkOrderNumber() {
|
||||
return workOrderNumber;
|
||||
}
|
||||
|
||||
public void setWorkOrderNumber(String workOrderNumber) {
|
||||
this.workOrderNumber = workOrderNumber;
|
||||
}
|
||||
|
||||
public int getLineNumber() {
|
||||
return lineNumber;
|
||||
}
|
||||
|
||||
public void setLineNumber(int lineNumber) {
|
||||
this.lineNumber = lineNumber;
|
||||
}
|
||||
|
||||
public String getMaterialNumber() {
|
||||
return materialNumber;
|
||||
}
|
||||
|
||||
public void setMaterialNumber(String materialNumber) {
|
||||
this.materialNumber = materialNumber;
|
||||
}
|
||||
|
||||
public int getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(int quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public String getRemarks() {
|
||||
return remarks;
|
||||
}
|
||||
|
||||
public void setRemarks(String remarks) {
|
||||
this.remarks = remarks;
|
||||
}
|
||||
|
||||
public String getLocationNumber() {
|
||||
return locationNumber;
|
||||
}
|
||||
|
||||
public void setLocationNumber(String locationNumber) {
|
||||
this.locationNumber = locationNumber;
|
||||
}
|
||||
|
||||
public String getFactory() {
|
||||
return factory;
|
||||
}
|
||||
|
||||
public void setFactory(String factory) {
|
||||
this.factory = factory;
|
||||
}
|
||||
|
||||
public String getLoc() {
|
||||
return loc;
|
||||
}
|
||||
|
||||
public void setLoc(String loc) {
|
||||
this.loc = loc;
|
||||
}
|
||||
|
||||
public Date getAllocationDate() {
|
||||
return allocationDate;
|
||||
}
|
||||
|
||||
public void setAllocationDate(Date allocationDate) {
|
||||
this.allocationDate = allocationDate;
|
||||
}
|
||||
}
|
||||
|
|
@ -97,9 +97,8 @@
|
|||
<property name="HighestStock" column="HIGHEST_STOCK" type="double" />
|
||||
<property name="barcode" column="BAR_CODE" type="string"
|
||||
length="150" />
|
||||
|
||||
<property name="beMarkWeight" type="boolean" column="BE_MARK_WEIGHT" />
|
||||
|
||||
<property name="beWholeLine" type="boolean" column="BE_WHOLE_LINE" />
|
||||
<property name="shipRules" type="string" column="SHIP_RULES" />
|
||||
<property name="packNumber" type="integer" column="PACK_NUMBER" />
|
||||
<property name="multipleOrder" type="double" column="MULTIPLE_ORDER" />
|
||||
|
|
|
|||
|
|
@ -5,9 +5,12 @@
|
|||
<hibernate-mapping>
|
||||
<class name="com.dev.swms.server.model.base.WorkOrderAllocationInfo" table="WorkOrderAllocationInfo">
|
||||
<!-- 定义主键 -->
|
||||
<id name="id" column="ID">
|
||||
<generator class="identity"/>
|
||||
</id>
|
||||
<id name="id" column="ID" type="long">
|
||||
<generator class="native">
|
||||
<param name="sequence">seq_wms_WorkOrderAllocationInfo</param>
|
||||
<param name="parameters">START WITH 1000</param>
|
||||
</generator>
|
||||
</id>
|
||||
<!-- 映射其他字段 -->
|
||||
<property name="workOrderNumber" column="WorkOrderNumber" type="string"/>
|
||||
<property name="lineNumber" column="LineNumber" type="integer"/>
|
||||
|
|
|
|||
|
|
@ -1097,6 +1097,7 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
LocationStorage ls = this.load(LocationStorage.class, id);
|
||||
AgvTask agvTask=EntityFactory.getEntity(AgvTask.class);
|
||||
agvTask.setRobotJobId(TimeNumberUtils.getBigTaskCode());
|
||||
agvTask.setEndSlotCode(ls.getOutLocation());
|
||||
agvTask.setSlotCode(ls.getOutLocation());
|
||||
agvTask.setWorkMode("WORKBIN_OUTBOUND");
|
||||
setContainerCode(stockLP, agvTask,ls);//料箱区接驳口
|
||||
|
|
@ -1532,7 +1533,6 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
agvTask.setContainerCode(stockLP);
|
||||
agvTask.setStationCode(ls.getGzzCode());
|
||||
agvTask.setBeforePutConfirm(true);
|
||||
|
||||
agvTask.setJobType("BUCKET_MOVE");
|
||||
agvTask.setType("呼叫货架");
|
||||
agvTask.setClassification(classification);
|
||||
|
|
@ -1541,8 +1541,6 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
agvTask.setNeedOperation(true);
|
||||
agvTask.setLetDownFlag(1);
|
||||
agvTask.setContainerCode(stockLP);
|
||||
// String hql=" select from AgvTask agv,CommonCode cc where agv.status='ATCALL' and cc."
|
||||
// + " and agv.endSlotCode="+ls.getOutLocation();
|
||||
agvTask.setEndSlotCode(ls.getOutLocation());
|
||||
agvTask.setIdentification(identification);
|
||||
agvTask.setFounderName(fname);
|
||||
|
|
@ -1552,6 +1550,7 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
if (flag) {
|
||||
agvTask.setCode(CountPlanCode);
|
||||
agvTask.setRobotJobId(TimeNumberUtils.getBigTaskCode());
|
||||
agvTask.setEndSlotCode(ls.getOutLocation());
|
||||
agvTask.setSlotCode(ls.getOutLocation());
|
||||
agvTask.setWorkMode("WORKBIN_OUTBOUND");
|
||||
setContainerCode(stockLP, agvTask,ls);
|
||||
|
|
@ -2088,7 +2087,7 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
+ " and agvTask.status in ('ATCALL') "
|
||||
+ " and agvTask.targetArea like '%"+loc.getName()+"%' "
|
||||
+ " and agvTask.errorMessage is null "
|
||||
+ " order by agvTask.jobPriorityType desc "
|
||||
+ " order by agvTask.jobPriorityType desc,agvTask.jobPriority desc "
|
||||
);
|
||||
for (AgvTask agvTask : agvTasks) {
|
||||
|
||||
|
|
@ -2109,7 +2108,7 @@ public class DefaultAgvTaskManager extends DefaultBaseManager implements AgvTask
|
|||
}
|
||||
}else if(agvTask.getClassification().equals("盘点")) {
|
||||
String sql="select agvTask.id from AgvTask agvTask where agvTask.classification='盘点' "
|
||||
+ " and agvTask.targetArea='"+agvTask.getTargetArea()+"'"
|
||||
// + " and agvTask.targetArea='"+agvTask.getTargetArea()+"'"
|
||||
+ " and agvTask.status in('ATCALL','ATWAIT','ATPICK','NONCHECKED') "
|
||||
+ " and agvTask.beIssue=true and agvTask.containerCode='"+agvTask.getContainerCode()+"'";
|
||||
List<Long> agvids=commonDao.findByQuery(sql);
|
||||
|
|
|
|||
|
|
@ -1074,7 +1074,8 @@ public class DefaultCountPlanManager extends DefaultBaseManager implements
|
|||
//查询库存
|
||||
if(inventorLogs.size()>0) {
|
||||
|
||||
String hql2=" from Inventory i where i.counPlan is null and i.queuedQuantity=0 and i.quantity>0 and i.status='已入库' ";
|
||||
String hql2=" from Inventory i where i.counPlan is null and i.queuedQuantity=0 "
|
||||
+ "and i.quantity>0 and i.status='已入库' and i.itemKey.item.id<>2254883 ";
|
||||
if(itemkeyids.length()>0) {
|
||||
itemkeyids=itemkeyids.substring(0, itemkeyids.length()-1);
|
||||
if(itemkeyids.length()>0) {
|
||||
|
|
@ -1133,7 +1134,8 @@ public class DefaultCountPlanManager extends DefaultBaseManager implements
|
|||
|
||||
}else {
|
||||
//料号库位盘点任务
|
||||
String hql=" from Inventory inv where inv.queuedQuantity=0 and inv.quantity>0 and inv.status='已入库' ";
|
||||
String hql=" from Inventory inv where inv.queuedQuantity=0 and inv.quantity>0 "
|
||||
+ "and inv.status='已入库' and i.itemKey.item.id<>2254883 ";
|
||||
//盘点等级
|
||||
if(countPlan.getCountCode()!=null&&!countPlan.getCountCode().equals("")) {
|
||||
String code="";
|
||||
|
|
@ -1752,55 +1754,44 @@ public class DefaultCountPlanManager extends DefaultBaseManager implements
|
|||
if(sts3.size()>0&&z2==0) {
|
||||
throw new BusinessException("堆垛区有盘点任务,必须勾选");
|
||||
}
|
||||
|
||||
// List<CountRecord> ddq=commonDao.findByQuery(" from CountRecord c where c.location.zone.name='7#地堆区' "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> ddq=quserCountPlanTask(1808L, countPlanId);//7#地堆区
|
||||
if(ddq.size()>0&&w31==0) {
|
||||
throw new BusinessException("7#地堆区有盘点任务,必须勾选");
|
||||
}
|
||||
|
||||
// List<CountRecord> ptkq3=commonDao.findByQuery(" from CountRecord c where c.location.zone.id=1768 "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> ptkq3=quserCountPlanTask(1768L, countPlanId);//7#3楼普通库
|
||||
if(ptkq3.size()>0&&w32==0) {
|
||||
throw new BusinessException("7#3楼普通库有盘点任务,必须勾选");
|
||||
}
|
||||
// List<CountRecord> hjjq=commonDao.findByQuery(" from CountRecord c where c.location.zone.name='3#焊接件区' "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> hjjq=quserCountPlanTask(1773L, countPlanId);//3#焊接件区
|
||||
if(hjjq.size()>0&&w33==0) {
|
||||
throw new BusinessException("3#焊接件区有盘点任务,必须勾选");
|
||||
}
|
||||
// List<CountRecord> blpq=commonDao.findByQuery(" from CountRecord c where c.location.zone.name='3#不良品区' "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> blpq=quserCountPlanTask(1798L, countPlanId);//3#不良品区
|
||||
if(blpq.size()>0&&w34==0) {
|
||||
throw new BusinessException("3#不良品区有盘点任务,必须勾选");
|
||||
}
|
||||
// List<CountRecord> ptkq4=commonDao.findByQuery(" from CountRecord c where c.location.zone.id=1783 "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> ptkq4=quserCountPlanTask(1783L, countPlanId);//7#4楼普通库
|
||||
|
||||
if(ptkq4.size()>0&&w35==0) {
|
||||
throw new BusinessException("7#4楼普通库有盘点任务,必须勾选");
|
||||
}
|
||||
// List<CountRecord> hxpq=commonDao.findByQuery(" from CountRecord c where c.location.zone.name='8#化学品区' "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> hxpq=quserCountPlanTask(1799L, countPlanId);//8#化学品区
|
||||
if(hxpq.size()>0&&w36==0) {
|
||||
throw new BusinessException("8#化学品区有盘点任务,必须勾选");
|
||||
}
|
||||
// List<CountRecord> qyq=commonDao.findByQuery(" from CountRecord c where c.location.zone.name='研发暂存区' "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
|
||||
List<CountRecord> qyq=quserCountPlanTask(1814L, countPlanId);//研发暂存区
|
||||
|
||||
if(qyq.size()>0&&w37==0) {
|
||||
throw new BusinessException("研发暂存区区有盘点任务,必须勾选");
|
||||
}
|
||||
|
||||
// List<CountRecord> yfrg=commonDao.findByQuery(" from CountRecord c where c.location.zone.id=1815 "
|
||||
// +" and c.countPlan.id="+countPlanId+" order by c.location.code");
|
||||
List<CountRecord> yfrg=quserCountPlanTask(1815L, countPlanId);//2#2研发人工区
|
||||
if(yfrg.size()>0&&w38==0) {
|
||||
throw new BusinessException("2#2研发人工区有盘点任务,必须勾选");
|
||||
|
|
|
|||
|
|
@ -184,6 +184,7 @@ public interface QueryAppManager extends BaseManager {
|
|||
* @param warehouseId
|
||||
* @return
|
||||
*/
|
||||
@Transactional
|
||||
JSONObject scanpickItemCode(String taskId,String jhItem,long userId,long warehouseId);
|
||||
/**
|
||||
* PC拣货 完成
|
||||
|
|
@ -505,7 +506,7 @@ public interface QueryAppManager extends BaseManager {
|
|||
JSONObject queryLoc(String taskIds,long userId,long warehouseId);
|
||||
|
||||
//查询合单完成的任务
|
||||
JSONObject exchangeOrder(String pickCode,long userId,long warehouseId);
|
||||
JSONObject exchangeOrder(String pickCode,String zone_code,long userId,long warehouseId);
|
||||
//查询合单完成的任务
|
||||
JSONObject queryNCR(String ncrCode,String locId,String itemCode,long userId,long warehouseId);
|
||||
|
||||
|
|
|
|||
|
|
@ -1592,8 +1592,10 @@ public class DefaultInterfaceReqManager extends DefaultBaseManager implements In
|
|||
jsonobj.put("INPUT", array);
|
||||
}
|
||||
if(pt!=null&&pt.getCode().indexOf("CP")==-1) {
|
||||
|
||||
doWmsReqSap(getPropertiesParm("ldxt.SAP")+ApiURL.doWmsReqSap, jsonobj.toString(),"状态"+pt.getCode());
|
||||
}
|
||||
|
||||
}
|
||||
}else {
|
||||
logger.info("无出库单明细");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1370,6 +1370,7 @@ public class DefaultInterfaceRespManager extends DefaultBaseManager implements I
|
|||
String unit=asn.has("unit")? asn.getString("unit"):"";//单位
|
||||
String metaValue=asn.has("metaValue")? asn.getString("metaValue"):"";//元值
|
||||
String currencyType=asn.has("currencyType")? asn.getString("currencyType"):"";//币种
|
||||
String USAGE=asn.has("USAGE")? asn.getString("USAGE"):"";//用途
|
||||
|
||||
if(applicant.equals("")) {
|
||||
meg+="申请人信息不全";
|
||||
|
|
|
|||
|
|
@ -17,6 +17,8 @@ import java.util.HashMap;
|
|||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
import java.util.concurrent.locks.ReentrantLock;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import org.hibernate.Query;
|
||||
|
|
@ -3595,6 +3597,9 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
String status = "0";
|
||||
String msg = "";
|
||||
String data = "";
|
||||
|
||||
|
||||
|
||||
try {
|
||||
if (userId > 0) {
|
||||
if (warehouseId > 0) {
|
||||
|
|
@ -3684,6 +3689,7 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
msg = e.getMessage();
|
||||
} finally {
|
||||
}
|
||||
|
||||
resultJson.put("status", status);
|
||||
resultJson.put("data", data);
|
||||
resultJson.put("msg", msg);
|
||||
|
|
@ -7362,8 +7368,7 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
+" max(t.countPlan.countQty),max(t.countPlan.countQty-t.countPlan.finishNo) "
|
||||
+ " from CountRecord t where t.needCount=0 and t.countPlan.status in('ISSUED','COUNT') "
|
||||
+ " and t.countCode is not null and t.delta=0 "
|
||||
+ " and t.location.zone.id in(1798,1773,1768"
|
||||
+ ",1783,1808,1799,1813,1811,1812,1814,1809,1786,1782,1815,1816,1817,1818,1819) ";
|
||||
+ " and t.location.zone.carrierType.id=3 ";
|
||||
if(z_id>0){
|
||||
sql+=" and t.location.zone.id="+z_id+" ";
|
||||
}
|
||||
|
|
@ -10348,7 +10353,7 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
return resultJson;
|
||||
}
|
||||
|
||||
public JSONObject exchangeOrder(String pickCode,long userId,long warehouseId){
|
||||
public JSONObject exchangeOrder(String pickCode,String zone_code,long userId,long warehouseId){
|
||||
JSONObject resultJson = new JSONObject();
|
||||
JSONArray jsondata = new JSONArray();
|
||||
String status="0";
|
||||
|
|
@ -10359,20 +10364,31 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
if (userId > 0) {
|
||||
if (warehouseId > 0) {
|
||||
Worker worker1=commonDao.load(Worker.class, userId);
|
||||
String sql ="select max(t.dateBill3),lc.code,t.BILLCODE,s.LP " +
|
||||
String sql ="select max(pt.UPDATE_TIME),lc.code as lc_code,"
|
||||
+ "t.BILLCODE,s.LP as s_lp,z.name as z_name, "
|
||||
+ " max(DATEDIFF(MINUTE,pt.UPDATE_TIME, GETDATE())) as orderDate "
|
||||
+ " , pt.equated_Quantity as soi " +
|
||||
" from task t " +
|
||||
" left join STOCK s on s.ID=t.DST_LP " +
|
||||
" left join LOCATION lc on lc.id=t.DST_LOC_ID " +
|
||||
" left join LOCATIONS lcs on lcs.id=lc.LOCATIONS_ID " +
|
||||
" left join LOCATION loc on loc.id=t.SRC_LOC_ID " +
|
||||
" left join zone z on z.id=loc.ZONE_ID " +
|
||||
" left join PICK_TICKET_DETAIL ptd on ptd.id=t.PICK_TICKET_DETAIL_ID " +
|
||||
" left join PICK_TICKET pt on pt.id=ptd.PICK_TICKET_ID " +
|
||||
" where t.INVENTORY_STATUS='合单完成' and t.dateBill3 is not NULL " +
|
||||
" and t.PLAN_QUANTITY>0 and t.MOVED_QUANTITY_MU>0 ";
|
||||
" and t.PLAN_QUANTITY>0 and t.MOVED_QUANTITY_MU>0 "
|
||||
+ " and lcs.id<>11 ";
|
||||
if(pickCode.length()>0) {
|
||||
sql+=" and t.BILLCODE like '%"+pickCode+"%' ";
|
||||
}
|
||||
sql+=" group by t.BILLCODE,s.LP,lc.code " +
|
||||
" order by max(t.dateBill3),t.BILLCODE,lc.code,s.LP ";
|
||||
if(zone_code!=null&&zone_code.length()>0) {
|
||||
sql+=" and z.name = '"+zone_code.trim()+"' ";
|
||||
}
|
||||
sql+=" group by t.BILLCODE,s.LP,lc.code,z.name,pt.equated_Quantity " +
|
||||
" order by pt.equated_Quantity desc,max(pt.UPDATE_TIME),t.BILLCODE,z.name,lc.code,s.LP ";
|
||||
Query query = session.createSQLQuery(sql);
|
||||
List<Object[]> list= (List<Object[]>)query.list();
|
||||
|
||||
if(list.size()>0) {
|
||||
for(Object [] obj:list) {
|
||||
JSONObject data1 = new JSONObject();
|
||||
|
|
@ -10380,14 +10396,35 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
String lcCode=obj[1]==null?"":obj[1].toString();
|
||||
String BILLCODE=obj[2]==null?"":obj[2].toString();
|
||||
String sLP=obj[3]==null?"":obj[3].toString();
|
||||
String zName=obj[4]==null?"":obj[4].toString();
|
||||
String ordeDate=obj[5]==null?"0":obj[5].toString();
|
||||
String soi=obj[6]==null?"":obj[6].toString();
|
||||
// data1.put("dateBill3", dateBill3);
|
||||
// logger.info(dateBill3);
|
||||
// logger.info(ordeDate);
|
||||
// logger.info(soi);
|
||||
data1.put("lcCode", lcCode);
|
||||
data1.put("BILLCODE", BILLCODE);
|
||||
data1.put("sLP", sLP);
|
||||
data1.put("zName", zName);
|
||||
if(soi!=null&&soi.length()>0) {
|
||||
data1.put("bgColour", "1");//1=红色加急,
|
||||
}else {
|
||||
if(Long.parseLong(ordeDate)>210) {
|
||||
data1.put("bgColour", "3");//3=浅蓝色,剩30分钟
|
||||
}else if(Long.parseLong(ordeDate)>180) {
|
||||
data1.put("bgColour", "2");//2=黄色,剩余60分钟
|
||||
}else {
|
||||
data1.put("bgColour", "0");//0=无颜色,
|
||||
}
|
||||
}
|
||||
jsondata.add(data1);
|
||||
}
|
||||
data=jsondata.toString();
|
||||
status = "1";
|
||||
}else {
|
||||
status = "0";
|
||||
msg = "无数据!";
|
||||
}
|
||||
} else {
|
||||
status = "2";
|
||||
|
|
@ -10451,9 +10488,6 @@ public class DefaultQueryAppManager extends DefaultBaseManager implements QueryA
|
|||
status = "2";
|
||||
msg = "NCR不能为空!";
|
||||
}
|
||||
|
||||
|
||||
|
||||
} else {
|
||||
status = "2";
|
||||
msg = "无仓库信息!";
|
||||
|
|
|
|||
|
|
@ -2889,18 +2889,7 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
|
|||
continue;
|
||||
}
|
||||
Date date=new Date();
|
||||
/**
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
|
||||
String dateString=sdf.format(date);
|
||||
Date date3=new Date();
|
||||
try {
|
||||
date3=sdf.parse(dateString);
|
||||
} catch (ParseException e) {
|
||||
// TODO 自动生成的 catch 块
|
||||
// e.printStackTrace();
|
||||
}
|
||||
**/
|
||||
if(ptd.getStrBill6()==null||ptd.getStrBill6().length()<=0){
|
||||
PickTicket pt=ptd.getPickTicket();
|
||||
//分配库存
|
||||
|
|
@ -2911,10 +2900,7 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
|
|||
if(noLoc!=null&&!noLoc.equals("")) {
|
||||
hql1+=" and i.itemKey.lotInfo.propC2 not in("+noLoc+")";
|
||||
}
|
||||
//指定序列号
|
||||
// if(ptd.getApplyDoc()!=null&&!ptd.getApplyDoc().equals("")) {
|
||||
// hql1+=" and i.barCode='"+ptd.getApplyDoc()+"'";
|
||||
// }
|
||||
|
||||
//自动创波,ddq1=3#不良品区,ddq2=3#焊接件区,ddq3=3#货架区,ddq4=3#料箱区,ddq5=7#3楼普通库,
|
||||
//ddq6=7#4楼普通库,ddq7=7#地堆区,ddq8=7#堆垛库,ddq9=8#化学品区
|
||||
String kqno="";
|
||||
|
|
@ -2957,12 +2943,6 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
|
|||
if(ptd.getNewLotInfo().getPropC1()!=null&&!ptd.getNewLotInfo().getPropC1().equals("")) {
|
||||
hql1+=" and i.itemKey.lotInfo.propC1='"+ptd.getNewLotInfo().getPropC1()+"'";
|
||||
}
|
||||
|
||||
// if(ptd.getNewLotInfo().getPropC2()!=null&&!ptd.getNewLotInfo().getPropC2().equals("")) {
|
||||
// hql1+=" and i.itemKey.lotInfo.propC2='"+ptd.getNewLotInfo().getPropC2()+"'";
|
||||
// }else {
|
||||
//
|
||||
// }
|
||||
if(ptd.getNewLotInfo().getPropC3()!=null&&!ptd.getNewLotInfo().getPropC3().equals("")) {
|
||||
hql1+=" and i.itemKey.lotInfo.propC3='"+ptd.getNewLotInfo().getPropC3()+"'";
|
||||
}else {
|
||||
|
|
@ -3078,6 +3058,7 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
|
|||
if(ptd.getItem().getIsBOM()) {
|
||||
hql1+=" and CONVERT(varchar(100), i.itemKey.lotInfo.propD2, 23)>='"+DateUtil.formatDateYMDToStr(new Date())+"'";
|
||||
}
|
||||
//
|
||||
|
||||
List<Inventory> Inventorys = commonDao.findByQuery(
|
||||
hql1+hql2,new String[] { "id" },new Object[] { ptd.getItem().getId() });
|
||||
|
|
@ -3094,6 +3075,7 @@ public class DefaultAutoAllocator extends DefaultBaseManager implements AutoAllo
|
|||
if (allocateQty == 0) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (unQty < allocateQty) {
|
||||
allocateQty = unQty;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2503,26 +2503,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
|
|||
//第二优先浅位空闲,深有货品
|
||||
public LocationStorage findLocationStorageFor7(Stock st) {
|
||||
//查询深浅都是空闲
|
||||
// String sql1="select loc.relevanceCode from LocationStorage loc where loc.status='FREE' and loc.disabled=false "
|
||||
// + " and loc.type='存储点' group by loc.relevanceCode having count(*)>=2 ";
|
||||
//查询最少的巷道
|
||||
// String rhql2=" select top 1 s1.locationStorage.agvZone from Stock s1 where s1.agvFlag=true "
|
||||
// + " and s1.locationStorage.warehouseArea.id=1766 "
|
||||
// + " and s1.locationStorage.gdType='"+st.getGdType()+"'"
|
||||
// + " group by s1.locationStorage.agvZone "
|
||||
// + " order by count(s1.id) asc ";
|
||||
//查询浅位是空闲,优先深位没有任务的空闲浅位
|
||||
// String sql2="select loc2.relevanceCode from LocationStorage loc2 where loc2.status='FREE' and loc2.sqType=1 "
|
||||
// + " and loc2.disabled=false "
|
||||
// + " and loc2.type='存储点' ";
|
||||
//深位有任务的关联号
|
||||
// String sql3=" select loc1.relevanceCode from LocationStorage loc1 where "
|
||||
// + " loc1.name not in( select t.toCellCode from LibraryTask t "
|
||||
// + " where t.status in('NONCHECKED','ATCALL','ATWAIT','ATWORK')) "
|
||||
// + " and loc1.name not in( select t1.fromCellCode from LibraryTask t1 "
|
||||
// + " where t1.status in('NONCHECKED','ATCALL','ATWAIT','ATWORK')) "
|
||||
// + " and loc1.disabled=false "
|
||||
// + " and loc1.type='存储点' ";
|
||||
|
||||
//查询有任务的库位
|
||||
String sql5=" select loc3.relevanceCode from LocationStorage loc3 where "
|
||||
+ " (loc3.name in( select t1.toCellCode from LibraryTask t1 "
|
||||
|
|
@ -2532,7 +2513,6 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
|
|||
+ " and loc3.disabled=false "
|
||||
+ " and loc3.type='存储点' ";
|
||||
|
||||
// sql2=sql2+" and loc2.relevanceCode not in("+sql5+") ";
|
||||
//立库有坐标点位的托盘
|
||||
String sql4=" select s2.locationStorage.id from Stock s2 where s2.locationStorage.id is not null and s2.LP like 'Y00%' ";
|
||||
|
||||
|
|
@ -2581,25 +2561,12 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
|
|||
//查询深浅都是空闲,对应的深位。
|
||||
String hql1="";
|
||||
//查询深浅都是空
|
||||
// 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() <= 3) {
|
||||
// //查询浅位是空
|
||||
// hql1=sql+" and l.relevanceCode in ( "+sql2+") and l.sqType=1 "
|
||||
// + " ";
|
||||
// ls = this.commonDao.findByQuery(hql1 + px_sql);
|
||||
// }
|
||||
// if(ls.size() <= 3) {
|
||||
// //查询深位是空
|
||||
// hql1=sql+" and l.relevanceCode in ( "+sql3
|
||||
// +") and l.sqType=2 ";
|
||||
// ls = this.commonDao.findByQuery(hql1 + px_sql);
|
||||
// }
|
||||
|
||||
|
||||
if (ls.size() <= 10) {
|
||||
if (ls.size() <= 15) {
|
||||
throw new BusinessException("无合适的存放位");
|
||||
} else {
|
||||
return ls.get(0);
|
||||
|
|
@ -2848,28 +2815,7 @@ public class DefaultMoveDocManager extends DefaultBaseManager implements MoveDoc
|
|||
public void sendLibraryTask() {
|
||||
startLibraryTask("602");
|
||||
startLibraryTask("604");
|
||||
// String hql1="select t.billCode from Task t where t.agvStatus=1 and t.endRegion in ('602','603') ";
|
||||
// String hql2="select t.billCode from Task t where t.agvStatus=1 and t.endRegion in ('604','605') ";
|
||||
// List<LibraryTask> l1=this.commonDao.findByQuery("from LibraryTask t where t.toCellCode in ('603','602') and t.status='OPEN'");
|
||||
// List<LibraryTask> l2=this.commonDao.findByQuery("from LibraryTask t where t.toCellCode in ('604','605') and t.status='OPEN'");
|
||||
// if(l1.size()>0){
|
||||
// hql1+=" and t.endRegion not in ('602','603')";
|
||||
// }
|
||||
// if(l2.size()>0){
|
||||
// hql2+=" and t.endRegion not in ('604','605')";
|
||||
// }
|
||||
// hql1+=" group by t.billCode";
|
||||
// hql2+=" group by t.billCode";
|
||||
// List<String> codes1=this.commonDao.findByQuery(hql1);
|
||||
// List<String> codes2=this.commonDao.findByQuery(hql2);
|
||||
// if(codes1.size()>0){
|
||||
// String code=codes1.get(0);
|
||||
// sendLibrartTask(code,"1");
|
||||
// }
|
||||
// if(codes2.size()>0){
|
||||
// String code=codes2.get(0);
|
||||
// sendLibrartTask(code,"2");
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -4196,18 +4142,9 @@ 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() <= 4) {
|
||||
// hql1=sql+" and l.relevanceCode in ( "+sql2+") and l.sqType=1 ";
|
||||
// ls = this.commonDao.findByQuery(hql1 + px_sql);
|
||||
// }
|
||||
// if(ls.size() <= 2) {
|
||||
// hql1=sql+" and l.relevanceCode in ( "+sql3
|
||||
// +") and l.sqType=2 ";
|
||||
// ls = this.commonDao.findByQuery(hql1 + px_sql);
|
||||
// ls = this.commonDao.findByQuery(hql1 + px_sql);
|
||||
// }
|
||||
|
||||
|
||||
if (ls.size() <= 5) {
|
||||
if (ls.size() <= 10) {
|
||||
throw new BusinessException("不存在合适的库位");
|
||||
} else {
|
||||
return ls.get(0);
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@ public interface WaveDocManager extends BaseManager {
|
|||
//地标码保存
|
||||
void saveInventory(List<Long> ids,Long zoneid);
|
||||
|
||||
|
||||
/**
|
||||
* 创建波次
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -4085,6 +4085,10 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
|
|||
long workerId,boolean reSAP,String spr,Long locid,String beUnpacking) {
|
||||
String errorMes = "";
|
||||
Task task = commonDao.load(Task.class, taskId);
|
||||
if(task.getNcrCode()!=null&&task.getNcrCode().length()>0
|
||||
&&spr!=null&&!spr.equals(task.getNcrCode())) {
|
||||
throw new BusinessException(spr+"输入错误");
|
||||
}
|
||||
Worker w = this.commonDao.load(Worker.class, workerId);
|
||||
if (w != null) {
|
||||
task.setOperator(w.getName());// 操作人
|
||||
|
|
@ -4109,6 +4113,9 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
|
|||
|
||||
Location srcLoc = commonDao.load(Location.class, srcLocId);// 目标库位
|
||||
Stock dstLP = commonDao.load(Stock.class, dstLPId);// 目标容器
|
||||
if(dstLP==null) {
|
||||
throw new BusinessException("无容器码,请绑定");
|
||||
}
|
||||
ItemKey itemKey =commonDao.load(ItemKey.class, task.getItemKey().getId());
|
||||
Item item = this.load(Item.class, itemKey.getItem().getId());
|
||||
Location loc = this.load(Location.class, task.getSrcLoc().getId());
|
||||
|
|
@ -4257,7 +4264,7 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
|
|||
commonDao.store(stock);
|
||||
}
|
||||
}
|
||||
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, task.getBillCode(), dstLoc, null,
|
||||
inventoryManager.addInventoryLog(InventoryLogType.SHIPPING, -1, task.getBillCode(), dstLoc, dstLP==null?"":dstLP.getLP(),
|
||||
srcInv.getItemKey(), srcInv.getStorageDate(), srcInv.getSOI(), pickedQuantity, null,
|
||||
srcInv.getStatus(), srcInv.getId(), "拣货", pt.getBillType(), workerId, srcInv.getBarCode(),
|
||||
task.getSrcLoc(),pt.getSourceType());
|
||||
|
|
@ -5955,10 +5962,12 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
|
|||
// array.add(jsonobj2);
|
||||
jsonobj.put("Input", Remark);
|
||||
String aaa="";
|
||||
|
||||
if(getPropertiesParm("ldxt.bz").equals("1")) {
|
||||
aaa=interfaceReqManager.doWmsReqSap(getPropertiesParm("ldxt.SAP")+ApiURL.doWmsReqSap, jsonobj.toString(),"sap容器"+Remark);
|
||||
|
||||
return OUTPUTS(aaa);
|
||||
}else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -10192,12 +10201,10 @@ public class DefaultPickTicketManager extends DefaultBaseManager implements Pick
|
|||
+ " and inv.quantity-inv.queuedQuantity>="+allocatedQuantity
|
||||
+ " ";
|
||||
if(rd.getBarCode()!=null&&rd.getBarCode().length()>0) {
|
||||
hql=" and inv.barCode='"+rd.getBarCode()+"' ";
|
||||
hql+=" and inv.barCode='"+rd.getBarCode()+"' ";
|
||||
}
|
||||
List<Inventory> invsList=commonDao.findByQuery(hql);
|
||||
// for(Inventory inventory:invsList) {
|
||||
//
|
||||
// }
|
||||
|
||||
if(invsList.size()>0) {
|
||||
Inventory inventory=invsList.get(0);
|
||||
Task task = createTask(inventory, ptd, allocatedQuantity);
|
||||
|
|
|
|||
|
|
@ -2419,7 +2419,6 @@ public class DefaultWaveDocManager extends DefaultBaseManager implements
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void hotWaveDoc(Date date1,Date date2 ,Integer longtiem,Integer lxqQty,Integer hjqQty,Integer lkqQty,boolean ddq,String pickCode
|
||||
,boolean ddq1,boolean ddq2,boolean ddq3,boolean ddq4,boolean ddq5,boolean ddq6,boolean ddq7,boolean ddq8,boolean ddq9,Integer taskQty,boolean beUrgent) {
|
||||
|
|
|
|||
|
|
@ -7,14 +7,11 @@ import java.io.IOException;
|
|||
import java.io.InputStreamReader;
|
||||
import java.io.PrintWriter;
|
||||
import java.math.BigDecimal;
|
||||
import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import javax.servlet.ServletConfig;
|
||||
import javax.servlet.ServletException;
|
||||
|
|
@ -28,13 +25,11 @@ import org.hibernate.Session;
|
|||
import org.springframework.beans.BeansException;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
import org.springframework.orm.hibernate3.support.HibernateDaoSupport;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.context.support.WebApplicationContextUtils;
|
||||
|
||||
import com.dev.energy.server.dao.CommonDao;
|
||||
import com.dev.energy.server.model.EntityFactory;
|
||||
import com.dev.energy.server.web.security.UserHolder;
|
||||
import com.dev.swms.server.model.base.BillType;
|
||||
import com.dev.energy.server.util.DateUtil;
|
||||
import com.dev.swms.server.model.base.ContainerType;
|
||||
import com.dev.swms.server.model.base.Equipment;
|
||||
import com.dev.swms.server.model.base.Item;
|
||||
|
|
@ -48,16 +43,12 @@ import com.dev.swms.server.model.base.Worker;
|
|||
import com.dev.swms.server.model.inventory.AgvTask;
|
||||
import com.dev.swms.server.model.inventory.Inventory;
|
||||
import com.dev.swms.server.model.inventory.InventoryLogType;
|
||||
import com.dev.swms.server.model.inventory.InventoryView;
|
||||
import com.dev.swms.server.model.inventory.Stock;
|
||||
import com.dev.swms.server.model.inventory.Task;
|
||||
import com.dev.swms.server.model.receiving.ASNDetail;
|
||||
import com.dev.swms.server.model.receiving.CarLoad;
|
||||
import com.dev.swms.server.model.receiving.InterWMStask;
|
||||
import com.dev.swms.server.model.receiving.MoveDocDetail;
|
||||
import com.dev.swms.server.model.receiving.ReceivingInventory;
|
||||
import com.dev.swms.server.model.receiving.STATUS;
|
||||
import com.dev.swms.server.model.receiving.StockStatus;
|
||||
import com.dev.swms.server.model.shipping.PickTicket;
|
||||
import com.dev.swms.server.model.shipping.PickTicketDetail;
|
||||
import com.dev.swms.server.model.shipping.PickTicketStatus;
|
||||
|
|
@ -65,7 +56,6 @@ import com.dev.swms.server.model.shipping.SeedWall;
|
|||
import com.dev.swms.server.service.interfaceLog.InterfaceReqManager;
|
||||
import com.dev.swms.server.service.interfaceLog.JdbcManager;
|
||||
import com.dev.swms.server.service.interfaceLog.QueryAppManager;
|
||||
import com.dev.swms.server.service.interfaceLog.WcsCSDCode;
|
||||
import com.dev.swms.server.service.inventory.InventoryManager;
|
||||
import com.dev.swms.server.service.receiving.ASNManager;
|
||||
import com.dev.swms.server.service.receiving.CarLoadManager;
|
||||
|
|
@ -74,8 +64,6 @@ import com.dev.swms.server.service.sequence.BussinessCodeManager;
|
|||
import com.dev.swms.server.service.shipping.PickTicketManager;
|
||||
import com.dev.swms.server.service.shipping.WaveDocManager;
|
||||
import com.dev.swms.server.utils.StringUtil;
|
||||
import com.dev.swms.server.utils.interfaceUtil;
|
||||
import com.dev.swms.server.web.filter.WarehouseHolder;
|
||||
|
||||
import net.sf.json.JSONArray;
|
||||
import net.sf.json.JSONObject;
|
||||
|
|
@ -113,6 +101,7 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
|
||||
logger.info("==========ASNReceiveServlet========"+new Date());
|
||||
CommonDao commonDao = (CommonDao) ac.getBean("commonDao");
|
||||
|
||||
request.setCharacterEncoding("utf-8");
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream(),"utf-8"));//post方式传递读取字符流
|
||||
String jsonStr = null;
|
||||
|
|
@ -123,9 +112,26 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
}
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
}finally {
|
||||
// 关闭 BufferedReader
|
||||
try {
|
||||
reader.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
logger.info("result:"+result.toString());
|
||||
JSONObject json= JSONObject.fromObject(result.toString());
|
||||
JSONObject json = null;
|
||||
try {
|
||||
// 尝试将字符串转换为 JSONObject
|
||||
json = JSONObject.fromObject(result.toString());
|
||||
} catch (Exception e) {
|
||||
logger.error("Failed to parse JSON: " + result.toString(), e);
|
||||
// 处理 JSON 解析失败的情况
|
||||
response.setStatus(HttpServletResponse.SC_BAD_REQUEST);
|
||||
return;
|
||||
}
|
||||
QueryAppManager app = (QueryAppManager) ac.getBean("queryAppManager");
|
||||
String methodType =json.has("methodType")?json.getString("methodType"):"";
|
||||
Long wId = json.has("wId")?Long.parseLong(json.getString("wId")):0l;
|
||||
|
|
@ -194,16 +200,18 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
resultJson=this.addIteminfo(specs,weight,length, width,height,z_id,asnDetailId,workerId, wId,commonDao);
|
||||
|
||||
}else if("receiving".equals(methodType)){
|
||||
SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd");
|
||||
// SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd");
|
||||
String asnDetailIds =json.has("asnDetailIds")?json.getString("asnDetailIds"):"";
|
||||
String serials =json.has("serials")?json.getString("serials"):"";
|
||||
String pc1_date =json.has("pc1_date")?json.getString("pc1_date"):"";
|
||||
Date date=null;
|
||||
try {
|
||||
date=sdf.parse(pc1_date);
|
||||
} catch (ParseException e) {
|
||||
date=new Date();
|
||||
}
|
||||
// try {
|
||||
date=DateUtil.formatStrToDateYMD(pc1_date);
|
||||
// } catch (ParseException e) {
|
||||
if(date==null) {
|
||||
date=new Date();
|
||||
}
|
||||
// }
|
||||
String propLC2 =json.has("propLC1")?json.getString("propLC1"):"";
|
||||
String propLC3 =json.has("propLC2")?json.getString("propLC2"):"";
|
||||
long locId = json.has("locId")?Long.parseLong(json.getString("locId").equals("")?"0":json.getString("locId")):0l;
|
||||
|
|
@ -449,7 +457,9 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
//PDA扫描料号
|
||||
String taskId =json.has("taskId")?json.getString("taskId"):"";
|
||||
String jhItem =json.has("jhItem")?json.getString("jhItem"):"";
|
||||
synchronized ("scanpickItemCode") {
|
||||
resultJson=app.scanpickItemCode(taskId,jhItem,workerId, wId);
|
||||
}
|
||||
}else if("picking".equals(methodType)){
|
||||
//拣货,完成按钮
|
||||
String taskId =json.has("taskId")?json.getString("taskId"):"";//
|
||||
|
|
@ -461,7 +471,7 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
String sid=json.has("s_id")?json.getString("s_id"):"";//容器
|
||||
String str_loc=json.has("str_loc")?json.getString("str_loc"):"";//LOC
|
||||
|
||||
String applicant=json.has("applicantName")?json.getString("applicantName"):"";//申请人
|
||||
String applicant=json.has("applicantName")?json.getString("applicantName"):"";//申请人NCR
|
||||
String location_id=json.has("location_id")?json.getString("location_id"):"0";//合单库位
|
||||
if(sid==null||sid.equals("")) {
|
||||
sid="0";
|
||||
|
|
@ -837,6 +847,14 @@ public class ASNReceiveServlet extends HttpServlet {
|
|||
e.printStackTrace();
|
||||
} finally {
|
||||
out.close();
|
||||
// 确保在处理完请求后释放资源
|
||||
if (commonDao instanceof AutoCloseable) {
|
||||
try {
|
||||
((AutoCloseable) commonDao).close();
|
||||
} catch (Exception e) {
|
||||
logger.error("Failed to close CommonDao", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -215,8 +215,8 @@ public class PickingServlet extends HttpServlet {
|
|||
}else if("exchangeOrder".equals(methodType)){
|
||||
//交单任务列表
|
||||
String p_code =json.has("p_code")?json.getString("p_code"):"";
|
||||
|
||||
resultJson=app.exchangeOrder(p_code, workerId, wId);
|
||||
String zone_code =json.has("name")?json.getString("name"):"";
|
||||
resultJson=app.exchangeOrder(p_code,zone_code, workerId, wId);
|
||||
}else if("queryNCR".equals(methodType)){
|
||||
//查询NCR
|
||||
String ncrCode =json.has("ncrCode")?json.getString("ncrCode"):"";
|
||||
|
|
|
|||
|
|
@ -337,11 +337,7 @@
|
|||
<value>com/dev/swms/server/model/base/location.hbm.xml</value>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
<bean id="workOrderAllocationInfoHibernateMappingResource" class="com.dev.energy.server.dao.hibernate.HibernateMappingResource">
|
||||
<constructor-arg>
|
||||
<value>com/dev/swms/server/model/base/workOrderAllocationInfo.hbm.xml</value>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
|
||||
<bean id="locationsHibernateMappingResource" class="com.dev.energy.server.dao.hibernate.HibernateMappingResource">
|
||||
<constructor-arg>
|
||||
<value>com/dev/swms/server/model/base/locations.hbm.xml</value>
|
||||
|
|
@ -1221,4 +1217,9 @@
|
|||
<value>com/dev/swms/server/model/base/sapOutType.hbm.xml</value>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
<!-- <bean id="workOrderAllocationInfoHibernateMappingResource" class="com.dev.energy.server.dao.hibernate.HibernateMappingResource"> -->
|
||||
<!-- <constructor-arg> -->
|
||||
<!-- <value>com/dev/swms/server/model/base/workOrderAllocationInfo.hbm.xml</value> -->
|
||||
<!-- </constructor-arg> -->
|
||||
<!-- </bean> -->
|
||||
</beans>
|
||||
|
|
@ -485,4 +485,6 @@ REFERENCES [ZONE](ID);
|
|||
GO
|
||||
----------2025-03-05
|
||||
ALTER TABLE task add small_Unit varchar(50) COLLATE Chinese_PRC_CI_AS NULL;
|
||||
GO
|
||||
GO
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -10,4 +10,28 @@ ON [PRIMARY]
|
|||
ON [PRIMARY]
|
||||
GO
|
||||
|
||||
ALTER TABLE [dbo].[ZONE_PLANT] SET (LOCK_ESCALATION = TABLE)
|
||||
ALTER TABLE [dbo].[ZONE_PLANT] SET (LOCK_ESCALATION = TABLE)
|
||||
|
||||
|
||||
--------2025-03-26
|
||||
ALTER TABLE Item add BE_WHOLE_LINE tinyint NULL;
|
||||
GO
|
||||
update Item set BE_WHOLE_LINE=0 where BE_WHOLE_LINE is null;
|
||||
GO
|
||||
|
||||
CREATE TABLE WorkOrderAllocationInfo (
|
||||
ID INT IDENTITY(1,1) PRIMARY KEY,
|
||||
WorkOrderNumber NVARCHAR(50),
|
||||
LineNumber INT,
|
||||
MaterialNumber NVARCHAR(50),
|
||||
Quantity INT,
|
||||
Remarks NVARCHAR(200),
|
||||
LocationNumber NVARCHAR(50),
|
||||
Factory NVARCHAR(50),
|
||||
LOC NVARCHAR(50),
|
||||
AllocationDate DATE
|
||||
);
|
||||
GO
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
col="2" readOnly="false" required="false" reserve="false"
|
||||
forceOverride="false" inVisible="false" trimSpace="true"
|
||||
isPrecision="true" />
|
||||
<booleanList id="carrierType.reDeposit" title="是否转入提示" defaultValue="false" row="2" col="1" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
<booleanList id="carrierType.reDeposit" title="转库确认原包装提示" defaultValue="false" row="2" col="1" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
|
||||
</inputUIs>
|
||||
<buttons>
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@
|
|||
where 1=1 order by plantInfo.name asc ]]></hql>
|
||||
</list>
|
||||
<booleanList id="pl.beWave" title="是否入波" defaultValue="false" row="2" col="1" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
<booleanList id="pl.beRegister" title="入库登记" defaultValue="false" row="2" col="2" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
<booleanList id="pl.beRegister" title="不良品入库" defaultValue="false" row="2" col="2" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
<booleanList id="pl.bePriorityWave" title="是否优先出库" defaultValue="false" row="3" col="1" span="1" readOnly="false" required="true" reserve="true" forceOverride="true" inVisible="false"/>
|
||||
<text id="pl.locFloor" title="位置" row="4" width="300"
|
||||
col="2" span="2" readOnly="false" required="false" reserve="false"
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@
|
|||
<column id="carrierType.id" title="carrierType.id" visible="false" />
|
||||
<column id="carrierType.code" title="工厂"
|
||||
visible="true" horizonAlign="center" />
|
||||
<column id="carrierType.reDeposit" title="是否转入提示"
|
||||
<column id="carrierType.reDeposit" title="转库确认原包装提示"
|
||||
visible="true" horizonAlign="center" verticalAlign="middle" format="booleanFormat"
|
||||
formatParam="disabled" />
|
||||
<column id="carrierType.disabled" title="location.disabled"
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@
|
|||
visible="true" horizonAlign="center" verticalAlign="middle" format="booleanFormat"
|
||||
formatParam="disabled" />
|
||||
<column id="pl.locFloor" title="位置" visible="true" horizonAlign="center" />
|
||||
<column id="pl.beRegister" title="入库登记"
|
||||
<column id="pl.beRegister" title="不良品入库"
|
||||
visible="true" horizonAlign="center" verticalAlign="middle" format="booleanFormat"
|
||||
formatParam="disabled" />
|
||||
<column id="pl.bePriorityWave" title="优先出库"
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@
|
|||
width="100" readOnly="false" required="false" reserve="false"
|
||||
forceOverride="true" inVisible="false" trimSpace="true"
|
||||
isPrecision="true" />
|
||||
<text id="w42" title="7#3楼地堆区" defaultValue="0" row="24" span="1" col="1"
|
||||
<text id="w42" title="7#3楼地堆区" defaultValue="0" row="24" span="2" col="1"
|
||||
width="100" readOnly="false" required="false" reserve="false"
|
||||
forceOverride="true" inVisible="false" trimSpace="true"
|
||||
isPrecision="true" />
|
||||
|
|
|
|||
|
|
@ -38,20 +38,7 @@
|
|||
<text id="dstLP.LP" title="容器" row="4" col="2" readOnly="false"
|
||||
required="false" reserve="false" forceOverride="false" inVisible="false"
|
||||
trimSpace="false" />
|
||||
<!-- <remote id="dstLP.LP" title="容器" row="4" col="2"
|
||||
readOnly="false" required="false" reserve="false" forceOverride="false"
|
||||
inVisible="false" editModel="normal" manualEditable="true"
|
||||
displayColumn="2" displayedTableHead="序号,容器编码,容器类型">
|
||||
<hql><![CDATA[select
|
||||
stock.id,
|
||||
stock.LP,
|
||||
stock.containerType.name
|
||||
from Stock stock
|
||||
where upper(stock.remark) like upper(:param)]]></hql>
|
||||
</remote> -->
|
||||
<!-- <text id="inventory.status" title="库存状态" row="5" col="1"
|
||||
readOnly="false" required="false" reserve="false" forceOverride="false"
|
||||
inVisible="false" trimSpace="false" /> -->
|
||||
|
||||
<list id="inventory.status" title="库存状态" row="7" col="2" width="120px"
|
||||
readOnly="false" required="false" reserve="false" forceOverride="false" >
|
||||
<hql><![CDATA[ select
|
||||
|
|
@ -147,9 +134,9 @@
|
|||
task.operateTime,
|
||||
task.dateBill3,
|
||||
task.dateBill3,
|
||||
case when task.positionStatus=1 then task.dateline when task.positionStatus=0 then '' end ,
|
||||
case when task.positionStatus=1 then task.dateline when task.positionStatus=0 then '' end,
|
||||
case when task.positionStatus=1 then '成功' when task.positionStatus=0 then '失败' else '未处理' end
|
||||
case when task.positionStatus='1' then task.dateline when task.positionStatus='0' then '' end ,
|
||||
case when task.positionStatus='1' then task.dateline when task.positionStatus='0' then '' end,
|
||||
case when task.positionStatus='1' then '成功' when task.positionStatus='0' then '失败' else '未处理' end
|
||||
|
||||
FROM Task task
|
||||
LEFT JOIN task.pickTicketDetail as pickTicketDetail
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ hibernate.dialect=com.dev.swms.server.utils.MSSQLDialect
|
|||
hibernate.show_sql=false
|
||||
hibernate.format_sql=false
|
||||
hibernate.hbm2ddl.auto=none
|
||||
ldxt.bz=1
|
||||
ldxt.bz=0
|
||||
hibernate.query.substitutions true=1, false=0
|
||||
#
|
||||
hibernate.max_fetch_depth=0
|
||||
|
|
|
|||
Loading…
Reference in New Issue