| | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.io.IOException; |
| | | import java.util.*; |
| | | |
| | | @RestController |
| | |
| | | return R.ok(); |
| | | } |
| | | |
| | | @RequestMapping(value = "/wrkMast/startWrk/auth") |
| | | @ManagerAuth(memo = "工作档开始任务") |
| | | public R startWrk(@RequestParam String param) throws IOException { |
| | | List<AgvWrkMast> agvWrkMastList = JSONArray.parseArray(param, AgvWrkMast.class); |
| | | if (Cools.isEmpty(agvWrkMastList)){ |
| | | return R.error(); |
| | | } |
| | | int startWrkCode = agvWrkMastService.startWrk(agvWrkMastList,"putaway"); |
| | | |
| | | int code = agvWrkMastService.containerMove(agvWrkMastList); |
| | | |
| | | if(code == 0){ |
| | | agvWrkMastList.forEach(agvWrkMast -> { |
| | | //202.RCS取货中 |
| | | agvWrkMast.setWrkSts((long)202); |
| | | //修改AGV入库通知档状态入出状态为Y |
| | | agvWaitPakinService.updateIoStatus(agvWrkMast.getWrkNo(),"Y"); |
| | | }); |
| | | agvWrkMastService.updateBatchById(agvWrkMastList); |
| | | |
| | | return R.ok("任务启动成功"); |
| | | } |
| | | |
| | | return R.error("任务启动失败"); |
| | | |
| | | } |
| | | // @RequestMapping(value = "/wrkMast/startWrk/auth") |
| | | // @ManagerAuth(memo = "工作档开始任务") |
| | | // public R startWrk(@RequestParam String param) throws IOException { |
| | | // List<AgvWrkMast> agvWrkMastList = JSONArray.parseArray(param, AgvWrkMast.class); |
| | | // if (Cools.isEmpty(agvWrkMastList)){ |
| | | // return R.error(); |
| | | // } |
| | | // int startWrkCode = agvWrkMastService.startWrk(agvWrkMastList,"putaway"); |
| | | // |
| | | // int code = agvWrkMastService.containerMoveIn(agvWrkMastList); |
| | | // |
| | | // if(code == 0){ |
| | | // agvWrkMastList.forEach(agvWrkMast -> { |
| | | // //202.RCS取货中 |
| | | // agvWrkMast.setWrkSts((long)202); |
| | | // //修改AGV入库通知档状态入出状态为Y |
| | | // agvWaitPakinService.updateIoStatus(agvWrkMast.getWrkNo(),"Y"); |
| | | // }); |
| | | // agvWrkMastService.updateBatchById(agvWrkMastList); |
| | | // |
| | | // return R.ok("任务启动成功"); |
| | | // } |
| | | // |
| | | // return R.error("任务启动失败"); |
| | | // |
| | | // } |
| | | } |