代码更新

This commit is contained in:
2023-02-04 21:42:25 +08:00
parent e19622efc3
commit b214dd2ebe
4 changed files with 239 additions and 225 deletions

View File

@@ -182,6 +182,7 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
@Transactional(rollbackFor = Exception.class)
public JSONObject apply(JSONObject whereJson) {
log.info("apply请求参数---------------------------------------------"+whereJson.toString());
synchronized (AcsToWmsServiceImpl.class) {
String type = whereJson.getString("type");
String device_code = whereJson.getString("device_code");
String vehicle_code = whereJson.getString("vehicle_code");
@@ -266,7 +267,7 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
} else {
// 双通
// 先倒序找到第一个木箱、判断上一个是否有货位
// 先倒序找到第一个托盘、判断上一个是否有货位
JSONObject jsonDescBox = WQLObject.getWQLObject("st_ivt_structattr").query("lock_type = '1' AND block_num = '" + block_num + "'AND placement_type = '" + placement_type + "' AND row_num = '" + row_num + "' AND is_delete = '0' AND is_used = '1' AND IFNULL(storagevehicle_code,'') <> '' order by out_order_seq DESC").uniqueResult(0);
String out_order_seq = jsonDescBox.getString("out_order_seq");
// 上一个货位顺序号
@@ -276,7 +277,7 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
if (ObjectUtil.isNotEmpty(jsonDescStruct)) {
struct_jo = jsonDescStruct;
} else {
// 没有就正序找到第一个物料、判断上一个是否有货位
// 没有就正序找到第一个托盘、判断上一个是否有货位
JSONObject jsonAscBox = WQLObject.getWQLObject("st_ivt_structattr").query("lock_type = '1' AND block_num = '" + block_num + "'AND placement_type = '" + placement_type + "' AND row_num = '" + row_num + "' AND is_delete = '0' AND is_used = '1' AND IFNULL(storagevehicle_code,'') <> '' order by out_order_seq ASC").uniqueResult(0);
String out_order_seq2 = jsonAscBox.getString("out_order_seq");
// 上一个货位顺序号
@@ -434,6 +435,9 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
return result;
}
}
@Override
public JSONObject deviceApply(JSONObject whereJson) {
log.info("deviceApply请求参数---------------------------------------------"+whereJson.toString());

View File

@@ -67,6 +67,10 @@ public class ProductionOutServiceImpl implements ProductionOutService {
if (ObjectUtil.isEmpty(box_no)) throw new BadRequestException("木箱不能为空");
JSONObject jsonPoint = pointTab.query("vehicle_code = '" + box_no + "' and is_delete = '0' and is_used = '1'").uniqueResult(0);
if (ObjectUtil.isEmpty(jsonPoint)) {
throw new BadRequestException("请输入正确的木箱");
}
/*
* 生产区确认
* a.解锁出库点位、清除木箱号

View File

@@ -943,12 +943,14 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
JSONObject map = new JSONObject();
map.put("flag", "5");
map.put("material_id", dtl.getString("material_id"));
map.put("box_no", dtl.getString("box_no"));
map.put("iostorinv_id", iostorinv_id);
map.put("iostorinvdtl_id", dtl.getString("iostorinvdtl_id"));
JSONArray dtlArr = WQL.getWO("ST_OUTIVT01").addParamMap(map).process().getResultJSONArray(0);
if (dtlArr.size() == 0) {
Struct_map.put(jsonIvt.getString("struct_id"), jsonIvt);
}
}
HashMap<String, String> map_dtl = new HashMap<String, String>();
//更新明细

View File

@@ -226,6 +226,10 @@
dtl.iostorinvdtl_id <> 输入.iostorinvdtl_id
ENDOPTION
OPTION 输入.box_no <> ""
dtl.box_no = 输入.box_no
ENDOPTION
ENDSELECT
ENDQUERY
ENDIF