| | |
| | | package com.zy.core.model.protocol; |
| | | |
| | | import com.core.common.SpringUtils; |
| | | import com.zy.asrs.entity.BasDevp; |
| | | import com.zy.asrs.entity.BasShuttleErr; |
| | | import com.zy.asrs.entity.LocMast; |
| | | import com.zy.asrs.service.BasDevpService; |
| | | import com.zy.asrs.service.BasShuttleErrService; |
| | | import com.zy.asrs.service.BasShuttleService; |
| | | import com.zy.asrs.service.LocMastService; |
| | |
| | | * 当前小车状态(内部自我维护) |
| | | */ |
| | | private Integer protocolStatus; |
| | | |
| | | // /** |
| | | // * 小车当前是否有货 |
| | | // * true:有货,false:无货 |
| | | // */ |
| | | // private Boolean loading = false; |
| | | |
| | | /** |
| | | * 当前小车状态枚举 |
| | |
| | | return basShuttleErr.getErrName(); |
| | | } |
| | | |
| | | public void setCurrentCode(Short currentCode) { |
| | | this.currentCode = currentCode; |
| | | LocMastService locMastService = SpringUtils.getBean(LocMastService.class); |
| | | if (locMastService != null) { |
| | | LocMast locMast = locMastService.queryByQrCode(currentCode.toString()); |
| | | if (locMast == null) { |
| | | //查不到库位号,查询是否为站点 |
| | | BasDevpService basDevpService = SpringUtils.getBean(BasDevpService.class); |
| | | if (basDevpService != null) { |
| | | BasDevp basDevp = basDevpService.queryByLocNo(currentCode.toString()); |
| | | if (basDevp != null) { |
| | | this.locNo = basDevp.getLocNo(); |
| | | } |
| | | } |
| | | }else{ |
| | | this.locNo = locMast.getLocNo(); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |