fix 反向组盘

This commit is contained in:
张江玮
2023-07-20 11:19:52 +08:00
parent 1b3a849fd7
commit 3e06329f58
5 changed files with 56 additions and 21 deletions

View File

@@ -516,6 +516,14 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
throw new BadRequestException("任务编码不能为空!");
}
JSONObject task = WQLObject.getWQLObject("sch_base_task").query("task_code = '" + task_code + "'").uniqueResult(0);
if (ObjectUtil.isEmpty(task)) {
throw new BadRequestException("未查询到任务 [" + task_code + "] ");
}
JSONObject vd_update = new JSONObject();
vd_update.put("vehicle_code", vehicle_code);
WQLObject.getWQLObject("st_ivt_vehicle_detail").update(vd_update, "vd_id = " + task.getString("group_id"));
JSONObject result = new JSONObject();
result.put("status", HttpStatus.OK.value());
result.put("message", "组盘成功!");