|
|
@ -89,14 +89,42 @@ public class HandheldServiceImpl implements HandheldService { |
|
|
|
case "3": |
|
|
|
interiorAisle(vehicle, device_code, param); |
|
|
|
break; |
|
|
|
case "4": |
|
|
|
applyDeliveryRacks(vehicle, device_code, param); |
|
|
|
break; |
|
|
|
default: |
|
|
|
break; |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 空载具送回货架 |
|
|
|
* |
|
|
|
* @param vehicle |
|
|
|
* @param device_code |
|
|
|
* @param param |
|
|
|
*/ |
|
|
|
private void applyDeliveryRacks(String vehicle, String device_code, JSONObject param) { |
|
|
|
MdBaseVehicle mdBaseVehicle = iMdBaseVehicleService.selectByVehicleCode(vehicle); |
|
|
|
if (ObjectUtil.isEmpty(mdBaseVehicle)) throw new BadRequestException("载具不存在!"); |
|
|
|
SchBasePoint schBasePoint = iSchBasePointService.selectByPointCode(device_code); |
|
|
|
if (ObjectUtil.isEmpty(schBasePoint)) throw new BadRequestException("设备点位不存在!"); |
|
|
|
AbstractTask connectorTask = taskFactory.getTask("RACKTask"); |
|
|
|
// 准备参数:设备编码
|
|
|
|
JSONObject jo = new JSONObject(); |
|
|
|
jo.put("device_code", device_code); |
|
|
|
jo.put("config_code", "RACKTask"); |
|
|
|
jo.put("create_mode", GeneralDefinition.AUTO_CREATION); |
|
|
|
jo.put("vehicle_code", vehicle); |
|
|
|
jo.put("vehicle_type", mdBaseVehicle.getVehicle_type()); |
|
|
|
jo.put("ext_data", param); |
|
|
|
connectorTask.apply(jo); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 内部过道送托盘 |
|
|
|
* |
|
|
|
* @param vehicle |
|
|
|
* @param device_code |
|
|
|
* @param param |
|
|
|