|
@ -12,6 +12,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
|
|
import com.google.gson.Gson; |
|
|
import com.google.gson.Gson; |
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
import org.nl.common.enums.region.RegionEnum; |
|
|
import org.nl.common.enums.region.RegionEnum; |
|
|
|
|
|
import org.nl.common.exception.BadRequestException; |
|
|
import org.nl.config.IdUtil; |
|
|
import org.nl.config.IdUtil; |
|
|
import org.nl.config.MapOf; |
|
|
import org.nl.config.MapOf; |
|
|
import org.nl.wms.ext.connector.service.dto.ConnectorDto; |
|
|
import org.nl.wms.ext.connector.service.dto.ConnectorDto; |
|
@ -94,14 +95,23 @@ public class SortingServiceImpl implements SortingService { |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
//TODO:叫料
|
|
|
//TODO:叫料
|
|
|
} else if (SortingEnum.TASK_TYPE_ONE.getValue().equals(task_type) && SortingEnum.NOT_EMPTY.getValue().equals(is_empty)) { |
|
|
} else if (SortingEnum.TASK_TYPE_ONE.getValue().equals(task_type) && SortingEnum.NOT_EMPTY.getValue().equals(is_empty)) { |
|
|
|
|
|
if (StrUtil.isEmpty(vehicle_code)) { |
|
|
|
|
|
return MapOf.of("status", 400, "msg", "载具号未传递!"); |
|
|
|
|
|
} |
|
|
taskParam.put("config_code", "SortingCMTTask"); |
|
|
taskParam.put("config_code", "SortingCMTTask"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
//TODO:将空托盘放到线边库
|
|
|
//TODO:将空托盘放到线边库
|
|
|
} else if (SortingEnum.TASK_TYPE_TWO.getValue().equals(task_type) && SortingEnum.IS_EMPTY.getValue().equals(is_empty)) { |
|
|
} else if (SortingEnum.TASK_TYPE_TWO.getValue().equals(task_type) && SortingEnum.IS_EMPTY.getValue().equals(is_empty)) { |
|
|
|
|
|
if (StrUtil.isEmpty(vehicle_code)) { |
|
|
|
|
|
return MapOf.of("status", 400, "msg", "载具号未传递!"); |
|
|
|
|
|
} |
|
|
taskParam.put("config_code", "SortingSNTTask"); |
|
|
taskParam.put("config_code", "SortingSNTTask"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
//TODO:将满料放到线边库
|
|
|
//TODO:将满料放到线边库
|
|
|
} else if (SortingEnum.TASK_TYPE_TWO.getValue().equals(task_type) && SortingEnum.NOT_EMPTY.getValue().equals(is_empty)) { |
|
|
} else if (SortingEnum.TASK_TYPE_TWO.getValue().equals(task_type) && SortingEnum.NOT_EMPTY.getValue().equals(is_empty)) { |
|
|
|
|
|
if (StrUtil.isEmpty(vehicle_code)) { |
|
|
|
|
|
return MapOf.of("status", 400, "msg", "载具号未传递!"); |
|
|
|
|
|
} |
|
|
taskParam.put("config_code", "SortingSMTTask"); |
|
|
taskParam.put("config_code", "SortingSMTTask"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
} |
|
|
} |
|
@ -109,12 +119,12 @@ public class SortingServiceImpl implements SortingService { |
|
|
//TODO:呼叫两个空笼框
|
|
|
//TODO:呼叫两个空笼框
|
|
|
if (SortingEnum.TASK_TYPE_ONE.getValue().equals(task_type) && SortingEnum.IS_EMPTY.getValue().equals(is_empty)) { |
|
|
if (SortingEnum.TASK_TYPE_ONE.getValue().equals(task_type) && SortingEnum.IS_EMPTY.getValue().equals(is_empty)) { |
|
|
taskParam.put("device_code", pointCode + "_01"); |
|
|
taskParam.put("device_code", pointCode + "_01"); |
|
|
taskParam.put("task_seq","1"); |
|
|
taskParam.put("task_seq", "1"); |
|
|
taskParam.put("config_code", "SortingTwoCNTTask"); |
|
|
taskParam.put("config_code", "SortingTwoCNTTask"); |
|
|
taskParam.put("task_code", task_code + "A"); |
|
|
taskParam.put("task_code", task_code + "A"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
taskParam.put("device_code", pointCode + "_02"); |
|
|
taskParam.put("device_code", pointCode + "_02"); |
|
|
taskParam.put("task_seq","2"); |
|
|
taskParam.put("task_seq", "2"); |
|
|
taskParam.put("task_code", task_code + "B"); |
|
|
taskParam.put("task_code", task_code + "B"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
//TODO:将两个笼框放到线边库
|
|
|
//TODO:将两个笼框放到线边库
|
|
@ -123,13 +133,13 @@ public class SortingServiceImpl implements SortingService { |
|
|
return MapOf.of("status", 400, "msg", "第二个笼框载具号未传递!"); |
|
|
return MapOf.of("status", 400, "msg", "第二个笼框载具号未传递!"); |
|
|
} |
|
|
} |
|
|
taskParam.put("config_code", "SortingSMTTask"); |
|
|
taskParam.put("config_code", "SortingSMTTask"); |
|
|
taskParam.put("task_seq","1"); |
|
|
taskParam.put("task_seq", "1"); |
|
|
taskParam.put("vehicle_code", jsonObject.getString("vehicle_code2")); |
|
|
taskParam.put("vehicle_code", jsonObject.getString("vehicle_code2")); |
|
|
taskParam.put("device_code", pointCode + "_02"); |
|
|
taskParam.put("device_code", pointCode + "_02"); |
|
|
taskParam.put("task_code", task_code + "B"); |
|
|
taskParam.put("task_code", task_code + "B"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|
taskParam.put("vehicle_code", vehicle_code); |
|
|
taskParam.put("vehicle_code", vehicle_code); |
|
|
taskParam.put("task_seq","2"); |
|
|
taskParam.put("task_seq", "2"); |
|
|
taskParam.put("device_code", pointCode + "_01"); |
|
|
taskParam.put("device_code", pointCode + "_01"); |
|
|
taskParam.put("task_code", task_code + "A"); |
|
|
taskParam.put("task_code", task_code + "A"); |
|
|
connectorTask.apply(taskParam); |
|
|
connectorTask.apply(taskParam); |
|
|