| | |
| | | } |
| | | |
| | | //找不到库位,抛出异常 |
| | | throw new CoolException("该楼层没有空库位"); |
| | | throw new CoolException("该楼层没有空接驳位"); |
| | | } |
| | | |
| | | /** |
| | | * 检索库位号 |
| | | * @return locNo 检索到的库位号 |
| | | */ |
| | | public AgvBasDevp getDevpNo(int type, int floor, String auto) { |
| | | // 目标库位 |
| | | AgvBasDevp basDevp = null; |
| | | |
| | | // 开始查找库位 ==============================>> |
| | | basDevp = getDevpNoAuto(type,floor,auto); |
| | | if (basDevp != null) { |
| | | return basDevp; |
| | | } |
| | | |
| | | //找不到库位,抛出异常 |
| | | throw new CoolException("该楼层没有空接驳位"); |
| | | } |
| | | |
| | | //随机取一个货位 |
| | |
| | | .like("dev_no","DB")); |
| | | } |
| | | |
| | | //随机取一个货位 |
| | | private AgvBasDevp getDevpNoAuto(int type,int floor,String auto){ |
| | | return agvBasDevpService.selectOne(new EntityWrapper<AgvBasDevp>() |
| | | .eq("loc_sts","O") |
| | | .eq("floor",floor) |
| | | .eq("loc_type1",type) |
| | | .eq("autoing",auto) |
| | | .like("dev_no","DB")); |
| | | } |
| | | |
| | | } |