| | |
| | | import com.core.annotations.ManagerAuth; |
| | | import com.core.common.R; |
| | | import com.zy.asrs.entity.AgvBasDevp; |
| | | import com.zy.asrs.entity.param.LocDetlAdjustParam; |
| | | import com.zy.asrs.service.AgvWorkService; |
| | | import com.zy.common.model.StartupDto; |
| | | import com.zy.common.web.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | |
| | | @Autowired |
| | | private AgvWorkService workService; |
| | | |
| | | //TODO 移动到AgvBasDevpController下面 |
| | | @RequestMapping("/create/waitPain/wrkMast/start") |
| | | @ManagerAuth(memo = "生成任务") |
| | | public R createWaitPainWrkMastStart(@RequestParam String param) { |
| | | |
| | | List<AgvBasDevp> agvBasDevpList = JSONArray.parseArray(param, AgvBasDevp.class); |
| | | |
| | | StartupDto startupDto = workService.createWaitPainWrkMastStart(agvBasDevpList, getUserId()); |
| | | workService.createWaitPainWrkMastStart(agvBasDevpList, getUserId(),false); |
| | | //return R.ok("任务号:" + startupDto.getWorkNo() + ";目标库位:" + startupDto.getLocNo()); |
| | | return R.ok("生成入库工作档成功"); |
| | | } |
| | | |
| | | @RequestMapping("/locDdetl/adjust/start") |
| | | @ManagerAuth(memo = "") |
| | | public R locDetlAdjustStart(@RequestBody LocDetlAdjustParam param) { |
| | | workService.adjustLocDetl(param, getUserId()); |
| | | return R.ok("库存调整成功"); |
| | | } |
| | | |
| | | @RequestMapping("/hand/control/wrkMast") |
| | | @ManagerAuth(memo = "手动处理工作档") |
| | | public R handControlWrkMast(@RequestParam String workNo, |
| | | @RequestParam Integer type){ |
| | | if (type == 1) { |
| | | workService.completeWrkMast(workNo, getUserId()); |
| | | return R.ok("工作档已完成"); |
| | | } else if (type == 2) { |
| | | workService.cancelWrkMast(workNo, getUserId()); |
| | | return R.ok("工作档已取消"); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | } |