| | |
| | | import com.zy.asrs.domain.dto.AxisBean; |
| | | import com.zy.asrs.domain.dto.WorkChartAxis; |
| | | import com.zy.asrs.domain.vo.LocChartPie; |
| | | import com.zy.asrs.entity.BasDevp; |
| | | import com.zy.asrs.entity.LocDetl; |
| | | import com.zy.asrs.entity.WrkDetl; |
| | | import com.zy.asrs.entity.WrkMast; |
| | | import com.zy.asrs.entity.*; |
| | | import com.zy.asrs.entity.result.LedCommand; |
| | | import com.zy.asrs.entity.result.MatDto; |
| | | import com.zy.asrs.mapper.ReportQueryMapper; |
| | | import com.zy.asrs.service.BasDevpService; |
| | | import com.zy.asrs.service.LocDetlService; |
| | | import com.zy.asrs.service.WrkDetlService; |
| | | import com.zy.asrs.service.WrkMastService; |
| | | import com.zy.asrs.service.*; |
| | | import com.zy.common.model.annotations.RateLimit; |
| | | import com.zy.common.properties.SlaveProperties; |
| | | import com.zy.common.service.CommonService; |
| | |
| | | private WrkDetlService wrkDetlService; |
| | | @Autowired |
| | | private LocDetlService locDetlService; |
| | | @Autowired |
| | | private BasCrnpService basCrnpService; |
| | | |
| | | |
| | | /** |
| | |
| | | }catch (Exception e){ |
| | | // log.error("工作档案明细输入电视机失败1:异常信息==》"+e); |
| | | } |
| | | wrkDetls.forEach(wrkDetl -> ledCommand.getMatDtos().add(new MatDto(wrkDetl.getMatnr(), wrkDetl.getMaktx(), wrkDetl.getAnfme(),wrkDetl.getWeight(),wrkDetl.getSpecs()))); |
| | | wrkDetls.forEach(wrkDetl -> ledCommand.getMatDtos().add(new MatDto(wrkDetl.getMatnr(), wrkDetl.getMaktx(), wrkDetl.getAnfme(),wrkDetl.getWeight(),wrkDetl.getSpecs(),wrkDetl.getModel()))); |
| | | } |
| | | commands.add(ledCommand); |
| | | |
| | | return R.ok().add(commands); |
| | | } |
| | | |
| | |
| | | */ |
| | | @GetMapping("/led/error") |
| | | public R monitorLedError(@RequestParam("ledId") Integer ledId) { |
| | | return R.ok(); |
| | | BasDevp basDevp =basDevpService.selectOne(new EntityWrapper<BasDevp>().eq("dev_no",ledId)); |
| | | if(Cools.isEmpty(basDevp)){ |
| | | return R.ok(); |
| | | } |
| | | if(Cools.isEmpty(basDevp.getArea())){ |
| | | return R.ok(); |
| | | } |
| | | if(basDevp.getLoading().equals("N")){ |
| | | basDevp.setArea(""); |
| | | basDevpService.updateById(basDevp); |
| | | return R.ok(); |
| | | } |
| | | String errorMsg = basDevp.getArea(); |
| | | |
| | | return R.ok().add(errorMsg); |
| | | } |
| | | |
| | | /** |
| | | * 设备异常通知 |
| | | */ |
| | | @GetMapping("/device/error") |
| | | public R monitorDeviceError() { |
| | | ArrayList<HashMap<String, Object>> list = new ArrayList<>(); |
| | | List<BasCrnp> basCrnpLiset=basCrnpService.selectList(new EntityWrapper<BasCrnp>()); |
| | | for (BasCrnp basCrnp : basCrnpLiset) { |
| | | HashMap<String, Object> map = new HashMap<>(); |
| | | if (basCrnp.getCrnErr() > 0) { |
| | | //故障中 |
| | | map.put("deviceNo", basCrnp.getCrnNo());//设备号-小车号 |
| | | map.put("errorMsg", basCrnp.getCrnErr$());//异常信息 |
| | | map.put("device", "四向车");//异常信息 |
| | | list.add(map); |
| | | } |
| | | } |
| | | return R.ok().add(list); |
| | | } |
| | | |
| | | /** |
| | | * 自动补零 |