| | |
| | | import com.zy.common.model.NavigateNode; |
| | | import com.zy.core.cache.SlaveConnection; |
| | | import com.zy.core.enums.SlaveType; |
| | | import com.zy.core.model.ForkLiftSlave; |
| | | import com.zy.core.model.protocol.ForkLiftStaProtocol; |
| | | import com.zy.core.properties.SlaveProperties; |
| | | import com.zy.core.thread.ForkLiftThread; |
| | | import com.zy.system.entity.Config; |
| | | import com.zy.system.service.ConfigService; |
| | |
| | | } |
| | | |
| | | for (ForkLiftStaProtocol forkLiftStaProtocol : forkLiftThread.getForkLiftStaProtocols()) { |
| | | list.add(forkLiftStaProtocol.getStaNo()); |
| | | list.add(forkLiftStaProtocol.getSiteId()); |
| | | } |
| | | |
| | | return list; |
| | |
| | | } |
| | | |
| | | //获取提升机站点 |
| | | public static ForkLiftStaProtocol getLiftStaByStaNo(Integer staNo) { |
| | | public static ForkLiftStaProtocol getLiftStaByStaNo(Integer siteId) { |
| | | DeviceConfigService deviceConfigService = SpringUtils.getBean(DeviceConfigService.class); |
| | | List<DeviceConfig> forkliftList = deviceConfigService.selectList(new EntityWrapper<DeviceConfig>() |
| | | .eq("device_type", String.valueOf(SlaveType.ForkLift))); |
| | |
| | | } |
| | | |
| | | for (ForkLiftStaProtocol forkLiftStaProtocol : forkLiftThread.getForkLiftStaProtocols()) { |
| | | if (forkLiftStaProtocol.getStaNo().equals(staNo)) { |
| | | if (forkLiftStaProtocol.getSiteId().equals(siteId)) { |
| | | return forkLiftStaProtocol; |
| | | } |
| | | } |