| | |
| | | private RedisUtil redisUtil; |
| | | @Autowired |
| | | private LocMastService locMastService; |
| | | @Autowired |
| | | private BasMapService basMapService; |
| | | @Autowired |
| | | private StationCycleCapacityService stationCycleCapacityService; |
| | | |
| | | @PostMapping("/system/running/status") |
| | | @ManagerAuth(memo = "系统运行状态") |
| | |
| | | vo.setErrorMsg(stationProtocol.getErrorMsg()); // 报警信息 |
| | | vo.setBarcode(stationProtocol.getBarcode()); // 条码 |
| | | vo.setWeight(stationProtocol.getWeight());//重量 |
| | | vo.setTaskWriteIdx(stationProtocol.getTaskWriteIdx());//任务可写区 |
| | | String stationStatus = StationStatusType.process(stationProtocol).toString().toLowerCase().replaceAll("_", "-"); |
| | | if (stationProtocol.isAutoing() && stationProtocol.isLoading() && stationProtocol.getTaskNo() > 0 && !stationProtocol.isRunBlock()) { |
| | | String taskClass = getStationTaskClass(stationProtocol.getTaskNo(), inTaskRange, outTaskRange); |
| | |
| | | return R.ok().add(vos); |
| | | } |
| | | |
| | | @GetMapping("/latest/data/station/cycle/capacity") |
| | | public R stationCycleCapacity() { |
| | | return R.ok().add(stationCycleCapacityService.getLatestSnapshot()); |
| | | } |
| | | |
| | | // @PostMapping("/latest/data/barcode") |
| | | // @ManagerAuth(memo = "条码扫描仪实时数据") |
| | | // public R barcodeLatestData(){ |
| | |
| | | @GetMapping("/map/{lev}/auth") |
| | | public R getLocMap(@PathVariable Integer lev) { |
| | | Object object = redisUtil.get(RedisKeyType.LOC_MAP_BASE.key); |
| | | if (object == null) { |
| | | return R.error("地图未初始化"); |
| | | List<List<HashMap<String, Object>>> mapNodeList = null; |
| | | if (object != null) { |
| | | mapNodeList = (List<List<HashMap<String, Object>>>) object; |
| | | } |
| | | List<List<HashMap<String, Object>>> mapNodeList = (List<List<HashMap<String, Object>>>) object; |
| | | List<LocMast> locMastList = locMastService.selectLocByLev(lev); |
| | | for (LocMast locMast : locMastList) { |
| | | String[] locType = locMast.getLocType().split("-"); |