修改
This commit is contained in:
@@ -167,8 +167,8 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
// 起点和终点确定 生成任务
|
||||
JSONObject param = new JSONObject();
|
||||
param.put("point_code1", start_pint_code);
|
||||
param.put("point_code2", jsonSb.getString("point_code"));
|
||||
param.put("point_code3", jsonSb.getString("point_code"));
|
||||
param.put("point_code2", jsonSb.getString("point_code")+"_K");
|
||||
param.put("point_code3", jsonSb.getString("point_code")+"_M");
|
||||
param.put("point_code4", point_code4);
|
||||
param.put("task_type", "010101");
|
||||
param.put("material_code", jsonRaw.getString("container_name"));
|
||||
@@ -197,8 +197,8 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
if (!StrUtil.equals(jsonRaw.getString("status"), "02")) throw new BadRequestException("工单状态不为空轴搬出");
|
||||
|
||||
//查询该母卷号对应的任务
|
||||
String container_name = whereJson.getString("container_name");
|
||||
JSONObject task_jo = WQLObject.getWQLObject("SCH_BASE_Task").query("material_code = '" + container_name + "' and task_status <> '07'").uniqueResult(0);
|
||||
String container_name = jsonRaw.getString("container_name");
|
||||
JSONObject task_jo = WQLObject.getWQLObject("SCH_BASE_Task").query("material_code = '" + container_name + "' and task_status <> '07' AND is_delete = '0'").uniqueResult(0);
|
||||
|
||||
// 查询生箔点位库存表
|
||||
JSONObject jsonSb = sbTab.query("ext_code = '" + jsonRaw.getString("resource_name") + "'and is_used = '1'").uniqueResult(0);
|
||||
@@ -208,7 +208,8 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
JSONArray paramArr = new JSONArray();
|
||||
JSONObject param = new JSONObject();
|
||||
param.put("device_code", jsonSb.getString("point_code"));
|
||||
param.put("option ", "1");
|
||||
param.put("task_code", task_jo.getString("task_code"));
|
||||
param.put("option", "1");
|
||||
paramArr.add(param);
|
||||
|
||||
WmsToAcsServiceImpl wmsToAcsService = new WmsToAcsServiceImpl();
|
||||
@@ -236,6 +237,29 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
JSONObject jsonRaw = rawTab.query("mfg_order_name = '" + raw_jo.getString("mfg_order_name") + "'").uniqueResult(0);
|
||||
if (!StrUtil.equals(jsonRaw.getString("status"), "03")) throw new BadRequestException("工单不为确认下卷");
|
||||
|
||||
//查询该母卷号对应的任务
|
||||
String container_name = jsonRaw.getString("container_name");
|
||||
JSONObject task_jo = WQLObject.getWQLObject("SCH_BASE_Task").query("material_code = '" + container_name + "' and task_status <> '07' AND is_delete = '0'").uniqueResult(0);
|
||||
|
||||
// 查询生箔点位库存表
|
||||
JSONObject jsonSb = rawTab.query("ext_code = '" + jsonRaw.getString("resource_name") + "'and is_used = '1'").uniqueResult(0);
|
||||
if (ObjectUtil.isEmpty(jsonSb)) throw new BadRequestException("点位不存在");
|
||||
|
||||
//下发ACS,执行取满放空的AGV动作
|
||||
JSONArray paramArr = new JSONArray();
|
||||
JSONObject param = new JSONObject();
|
||||
param.put("device_code", jsonSb.getString("point_code"));
|
||||
param.put("task_code", task_jo.getString("task_code"));
|
||||
param.put("option", "2");
|
||||
paramArr.add(param);
|
||||
|
||||
WmsToAcsServiceImpl wmsToAcsService = new WmsToAcsServiceImpl();
|
||||
JSONObject result = wmsToAcsService.updateTask(paramArr);
|
||||
|
||||
if (!StrUtil.equals(result.getString("status"), "200")) {
|
||||
throw new BadRequestException("操作失败:" + result.getString("message "));
|
||||
}
|
||||
|
||||
// 更新工单状态为下卷完成
|
||||
jsonRaw.put("status", "04");
|
||||
rawTab.update(jsonRaw);
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
OPTION 输入.is_used <> ""
|
||||
is_used = 输入.is_used
|
||||
ENDOPTION
|
||||
OPTION 输入.is_used <> ""
|
||||
OPTION 输入.point_location <> ""
|
||||
point_location = 输入.point_location
|
||||
ENDOPTION
|
||||
OPTION 输入.begin_time <> ""
|
||||
|
||||
@@ -49,7 +49,7 @@ public class CutConveyorTask extends AbstractAcsTask {
|
||||
.task_type(json.getString("acs_task_type"))
|
||||
.start_device_code(json.getString("point_code1"))
|
||||
.next_device_code(json.getString("point_code2"))
|
||||
.vehicle_code(json.getString("vehicle_code"))
|
||||
.vehicle_code(json.getString("vehicle_code2"))
|
||||
.priority(json.getString("priority"))
|
||||
.remark(json.getString("remark"))
|
||||
.build();
|
||||
|
||||
Reference in New Issue
Block a user