| | |
| | | return response; |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | }finally { |
| | | String sourceLocNo = Utils.getLocNo(command.getSourcePosX(), command.getSourcePosY(), command.getSourcePosZ()); |
| | | String targetLocNo = Utils.getLocNo(command.getDestinationPosX(), command.getDestinationPosY(), command.getDestinationPosZ()); |
| | | |
| | | // 日志记录 |
| | | BasCrnpOptService bean = SpringUtils.getBean(BasCrnpOptService.class); |
| | | BasCrnpOpt basCrnpOpt = new BasCrnpOpt( |
| | | command.getTaskNo().intValue(), // 任务号 |
| | | command.getCrnNo(), // 堆垛机[非空] |
| | | new Date(), // 下发时间 |
| | | String.valueOf(command.getTaskMode()), // 模式 |
| | | sourceLocNo, //源库位 |
| | | targetLocNo, //目标库位 |
| | | null, // 修改时间 |
| | | null, // 修改人员 |
| | | null, // 备注 |
| | | JSON.toJSONString(command), // 指令 |
| | | JSON.toJSONString(getStatus()), // 系统状态 |
| | | 1, // 下发状态{0:未下发,1:已下发} |
| | | JSON.toJSONString(response) // 响应 |
| | | ); |
| | | bean.insert(basCrnpOpt); |
| | | } |
| | | return response; |
| | | } |