| | |
| | | import com.core.common.SpringUtils; |
| | | import com.zy.asrs.entity.BasSte; |
| | | import com.zy.asrs.service.BasSteService; |
| | | import com.zy.core.News; |
| | | import com.zy.core.enums.SteHisTaskStatusType; |
| | | import com.zy.core.enums.SteLocaType; |
| | | import com.zy.core.enums.SteStatusType; |
| | |
| | | * 电池电量 |
| | | */ |
| | | public Float charge = 0.0F; |
| | | |
| | | public void setCharge(Float charge) { |
| | | if (charge >= 0) { |
| | | this.charge = charge; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 满电 |
| | |
| | | String chargeLine = SpringUtils.getBean(BasSteService.class).selectById(this.steNo).getChargeLine(); |
| | | return charge > Float.parseFloat(chargeLine); |
| | | } catch (Exception e) { |
| | | log.error("fail", e); |
| | | News.error("fail", e); |
| | | return false; |
| | | } |
| | | } |
| | |
| | | } |
| | | |
| | | public Boolean isEnable() { |
| | | if (Cools.isEmpty(row)) { |
| | | if (row == 0) { |
| | | return false; |
| | | } |
| | | if (Cools.isEmpty(row, bay, lev)) { |
| | | return false; |
| | | } |
| | | if (Cools.isEmpty(bay)) { |
| | | if (bay == 0) { |
| | | return false; |
| | | } |
| | | } |
| | | if (Cools.isEmpty(lev)) { |
| | | if (lev == 0) { |
| | | return false; |
| | | } |
| | | } |
| | | return true; |
| | | return row > 0 && bay > 0 && lev > 0; |
| | | } |
| | | |
| | | } |