| | |
| | | @PostMapping("/arm/task/v1") |
| | | @AppAuth(memo = "分拣线上报接收") |
| | | public synchronized R TaskArmReport(@RequestHeader(required = false) String appkey, |
| | | @RequestBody TaskArmReportParam param, |
| | | HttpServletRequest request) { |
| | | @RequestBody TaskArmReportParam param, |
| | | HttpServletRequest request) { |
| | | auth(appkey, param, request); |
| | | if (Cools.isEmpty(param)) { |
| | | return R.parse(BaseRes.PARAM); |
| | |
| | | @PostMapping("/arm/task/cycle_result") |
| | | @AppAuth(memo = "单码完成") |
| | | public synchronized R TaskArmCycleResult(@RequestHeader(required = false) String appkey, |
| | | @RequestBody TaskArmCycleResultParam param, |
| | | HttpServletRequest request) { |
| | | @RequestBody TaskArmCycleResultParam param, |
| | | HttpServletRequest request) { |
| | | auth(appkey, param, request); |
| | | if (Cools.isEmpty(param)) { |
| | | return R.parse(BaseRes.PARAM); |
| | |
| | | @PostMapping("/arm/task/workspace_status") |
| | | @AppAuth(memo = "托盘完成") |
| | | public synchronized R TaskArmWorkspaceStatus(@RequestHeader(required = false) String appkey, |
| | | @RequestBody TaskArmWorkspaceStatusParam param, |
| | | HttpServletRequest request) { |
| | | @RequestBody TaskArmWorkspaceStatusParam param, |
| | | HttpServletRequest request) { |
| | | auth(appkey, param, request); |
| | | if (Cools.isEmpty(param)) { |
| | | return R.parse(BaseRes.PARAM); |
| | |
| | | @PostMapping("/arm/task/loc_status") |
| | | // @AppAuth(memo = "托盘就绪状态查询") |
| | | public synchronized R TaskArmLocStatus(@RequestHeader(required = false) String appkey, |
| | | @RequestBody ArmOKParam param, |
| | | HttpServletRequest request) { |
| | | @RequestBody ArmOKParam param, |
| | | HttpServletRequest request) { |
| | | auth(appkey, param, request); |
| | | if (Cools.isEmpty(param)) { |
| | | return R.parse(BaseRes.PARAM); |
| | |
| | | @PostMapping("/armAbnormalOperation") |
| | | // @AppAuth(memo = "异常上报") |
| | | public synchronized R ArmAbnormalOperation(@RequestHeader(required = false) String appkey, |
| | | @RequestBody TaskArmErrorParam param, |
| | | HttpServletRequest request) { |
| | | @RequestBody TaskArmErrorParam param, |
| | | HttpServletRequest request) { |
| | | auth(appkey, param, request); |
| | | if (Cools.isEmpty(param.getArm_no())) { |
| | | return R.error("机械臂编号[Arm_no]不能为空"); |
| | |
| | | int countWrk = wrkDetlService.selectCount(new EntityWrapper<WrkDetl>().eq("zpallet", mesToCombParam.getPalletId())); |
| | | int countwait = waitPakinService.selectCount(new EntityWrapper<WaitPakin>().eq("zpallet",mesToCombParam.getPalletId()).eq("io_status", "Y")); |
| | | if (countLoc > 0 || countWrk > 0 || countwait > 0) { |
| | | return R.error(mesToCombParam.getPalletId()+"-工作档/库存条码数据已存在,无法删除"); |
| | | return R.error(mesToCombParam.getPalletId()+"-工作档/库存条码数据已存在,无法删除"); |
| | | } |
| | | waitPakinService.delete(new EntityWrapper<WaitPakin>().eq("zpallet",mesToCombParam.getPalletId())); |
| | | boo = true; |
| | |
| | | |
| | | AxisBean cube5 = new AxisBean(); |
| | | cube5.setName("入库体积"); |
| | | AxisBean cube15 = new AxisBean(); |
| | | cube15.setName("出库体积"); |
| | | List<WorkCubeTotalAxis> workCubeTotalAxes = reportQueryMapper.getCubeTotal(); |
| | | List<WorkCubeTotalAxis> workCubeTotalAxes = reportQueryMapper.getInboundCubeTotal(); |
| | | Map<String, WorkCubeTotalAxis> cubeMap = new HashMap<String, WorkCubeTotalAxis>(); |
| | | if (workCubeTotalAxes != null) { |
| | | for (WorkCubeTotalAxis w : workCubeTotalAxes) { |
| | |
| | | } |
| | | } |
| | | ArrayList<Number> data4 = new ArrayList<Number>(); |
| | | ArrayList<Number> data5 = new ArrayList<Number>(); |
| | | SimpleDateFormat sfCube = new SimpleDateFormat("yyyy-MM-dd"); |
| | | Calendar calendarCube = Calendar.getInstance(); |
| | | calendarCube.add(Calendar.DATE, -12); |
| | |
| | | String str = sfCube.format(calendarCube.getTime()); |
| | | WorkCubeTotalAxis cubeAxis = cubeMap.get(str); |
| | | data4.add(cubeAxis == null || cubeAxis.getCube5Total() == null ? 0 : cubeAxis.getCube5Total()); |
| | | data5.add(cubeAxis == null || cubeAxis.getCube15Total() == null ? 0 : cubeAxis.getCube15Total()); |
| | | } |
| | | Number[] array4 = new Number[data4.size()]; |
| | | cube5.setData(data4.toArray(array4)); |
| | | list.add(cube5); |
| | | Number[] array5 = new Number[data5.size()]; |
| | | cube15.setData(data5.toArray(array5)); |
| | | list.add(cube15); |
| | | |
| | | } |
| | | map.put("rows",list); |
| | | return R.ok(map); |
| | |
| | | * 入出库按小时折线:横轴为「当前整点起向前共 12 小时」滚动窗口,与库表 ymd(yyyy-MM-dd HH)对齐 |
| | | */ |
| | | @GetMapping("/line/charts/hourly") |
| | | public synchronized R locIoLineChartsHourly() { |
| | | public synchronized R locIoLineChartsHourly() { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | List<AxisBean> list = new ArrayList<>(); |
| | | |