| | |
| | | import com.zy.asrs.framework.common.SpringUtils; |
| | | import com.zy.asrs.framework.exception.CoolException; |
| | | import com.zy.asrs.wcs.common.ExecuteSupport; |
| | | import com.zy.asrs.wcs.core.domain.dto.BasLiftStaDto; |
| | | import com.zy.asrs.wcs.core.entity.BasLift; |
| | | import com.zy.asrs.wcs.core.model.command.LiftCommand; |
| | | import com.zy.asrs.wcs.core.model.enums.LiftCommandModeType; |
| | |
| | | private LiftProtocol liftProtocol; |
| | | private SiemensS7Net siemensS7Net; |
| | | private List<LiftStaProtocol> liftStaProtocols = new ArrayList<>(); |
| | | private List<Sta> staList = new ArrayList<>(); |
| | | private List<BasLiftStaDto> staList = new ArrayList<>(); |
| | | |
| | | public NyLiftThread(Device device, RedisUtil redisUtil) { |
| | | this.device = device; |
| | |
| | | BasLiftService basLiftService = SpringUtils.getBean(BasLiftService.class); |
| | | BasLift basLift = basLiftService.getOne(new LambdaQueryWrapper<BasLift>() |
| | | .eq(BasLift::getDeviceId, device.getId())); |
| | | List<Sta> staList = JSON.parseArray(basLift.getSta(), Sta.class); |
| | | List<BasLiftStaDto> staList = JSON.parseArray(basLift.getSta(), BasLiftStaDto.class); |
| | | this.staList = staList; |
| | | for (Sta sta : staList) { |
| | | for (BasLiftStaDto sta : staList) { |
| | | LiftStaProtocol liftStaProtocol = new LiftStaProtocol(); |
| | | liftStaProtocol.setStaNo(sta.getStaNo());//站点号 |
| | | liftStaProtocol.setLev(sta.getLev());//站点楼层 |
| | |
| | | * 提升机号 |
| | | */ |
| | | private Integer liftNo; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class Sta { |
| | | |
| | | // 提升机站点号 |
| | | private Integer staNo; |
| | | |
| | | //输送站点排 |
| | | private Integer row; |
| | | |
| | | //输送站点列 |
| | | private Integer bay; |
| | | |
| | | // 层 |
| | | private Integer lev; |
| | | |
| | | } |
| | | |