psh 11 months ago
parent
commit
e36c5faea8
  1. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task/controller/SchBaseTaskController.java
  2. 11
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/BPSLTask.java
  3. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/KGHJRKTask.java
  4. 15
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/TBXBKJTask.java
  5. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/XSCKTask.java
  6. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ZJBZKDDTask.java
  7. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ghs/GHSFMTask.java
  8. 2
      lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ghs/GHSQHTask.java

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task/controller/SchBaseTaskController.java

@ -29,7 +29,7 @@ import java.util.Set;
@RestController @RestController
@Api(tags = "任务管理管理") @Api(tags = "任务管理管理")
@RequestMapping("/api/schBaseTask") @RequestMapping("/api/schBaseTask")
@Lazy
public class SchBaseTaskController { public class SchBaseTaskController {
@Autowired @Autowired

11
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/BPSLTask.java

@ -29,6 +29,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -44,6 +45,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("BPSLTask") @TaskType("BPSLTask")
@Lazy
public class BPSLTask extends AbstractTask { public class BPSLTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "BPSLTask"; private static String TASK_CONFIG_CODE = "BPSLTask";
/** /**
@ -95,8 +97,8 @@ public class BPSLTask extends AbstractTask {
//发起任务时先把点位占用,防止发起重复任务 //发起任务时先把点位占用,防止发起重复任务
// point.setIng_task_code(task.getTask_code()); // point.setIng_task_code(task.getTask_code());
// point.setVehicle_qty(point.getVehicle_qty() - 1); // point.setVehicle_qty(point.getVehicle_qty() - 1);
point.setVehicle_type(materialType); // point.setVehicle_type(materialType);
pointService.update(point); // pointService.update(point);
//下发 //下发
this.renotifyAcs(task); this.renotifyAcs(task);
@ -231,5 +233,10 @@ public class BPSLTask extends AbstractTask {
JSONObject jsonObject = JSONObject.parseObject(schBaseTask.getExt_group_data()); JSONObject jsonObject = JSONObject.parseObject(schBaseTask.getExt_group_data());
SchBasePoint point = this.findNextPoint(jsonObject); SchBasePoint point = this.findNextPoint(jsonObject);
schBaseTask.setPoint_code1(point.getPoint_code()); schBaseTask.setPoint_code1(point.getPoint_code());
//重算点位时把点位占用
point.setIng_task_code(schBaseTask.getTask_code());
// point.setVehicle_qty(point.getVehicle_qty() - 1);
// point.setVehicle_type(materialType);
pointService.update(point);
} }
} }

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/KGHJRKTask.java

@ -28,6 +28,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -43,6 +44,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("KGHJRKTask") @TaskType("KGHJRKTask")
@Lazy
public class KGHJRKTask extends AbstractTask { public class KGHJRKTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "KGHJRKTask"; private static String TASK_CONFIG_CODE = "KGHJRKTask";
/** /**

15
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/TBXBKJTask.java

@ -28,6 +28,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -43,6 +44,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("TBXBKJTask") @TaskType("TBXBKJTask")
@Lazy
public class TBXBKJTask extends AbstractTask { public class TBXBKJTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "TBXBKJTask"; private static String TASK_CONFIG_CODE = "TBXBKJTask";
/** /**
@ -95,12 +97,6 @@ public class TBXBKJTask extends AbstractTask {
task.setRemark(""); task.setRemark("");
taskService.update(task); taskService.update(task);
//发起任务时先把点位占用,防止发起重复任务
point.setIng_task_code(task.getTask_code());
//空固化架区别于组盘,任务完成后再扣除库存
// point.setVehicle_qty(point.getVehicle_qty() - 1);
pointService.update(point);
//下发 //下发
this.renotifyAcs(task); this.renotifyAcs(task);
} }
@ -122,7 +118,7 @@ public class TBXBKJTask extends AbstractTask {
} }
List<SchBasePoint> schBasePointList = pointMapper.findPointByRegion(regionCode,"1"); List<SchBasePoint> schBasePointList = pointMapper.findPointByRegion(regionCode,"1");
for (SchBasePoint schBasePoint : schBasePointList) { for (SchBasePoint schBasePoint : schBasePointList) {
if (schBasePoint.getVehicle_qty() > 0) { if (schBasePoint.getVehicle_qty() > 0&&ObjectUtil.isEmpty(schBasePoint.getIng_task_code())) {
log.info("涂板线补空架找到当前符合条件的点位{}",schBasePoint.getPoint_code()); log.info("涂板线补空架找到当前符合条件的点位{}",schBasePoint.getPoint_code());
return schBasePoint; return schBasePoint;
} }
@ -190,5 +186,10 @@ public class TBXBKJTask extends AbstractTask {
.eq(SchBasePoint::getPoint_code, schBaseTask.getPoint_code2())); .eq(SchBasePoint::getPoint_code, schBaseTask.getPoint_code2()));
SchBasePoint point = this.findNextPoint(startPoint); SchBasePoint point = this.findNextPoint(startPoint);
schBaseTask.setPoint_code1(point.getPoint_code()); schBaseTask.setPoint_code1(point.getPoint_code());
//重算点位时把点位占用,防止发起重复任务
point.setIng_task_code(schBaseTask.getTask_code());
//空固化架区别于组盘,任务完成后再扣除库存
// point.setVehicle_qty(point.getVehicle_qty() - 1);
pointService.update(point);
} }
} }

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/XSCKTask.java

@ -29,6 +29,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -44,6 +45,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("XSCKTask") @TaskType("XSCKTask")
@Lazy
public class XSCKTask extends AbstractTask { public class XSCKTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "XSCKTask"; private static String TASK_CONFIG_CODE = "XSCKTask";
/** /**

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ZJBZKDDTask.java

@ -28,6 +28,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -43,6 +44,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("ZJBZKDDTask") @TaskType("ZJBZKDDTask")
@Lazy
public class ZJBZKDDTask extends AbstractTask { public class ZJBZKDDTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "ZJBZKDDTask"; private static String TASK_CONFIG_CODE = "ZJBZKDDTask";
/** /**

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ghs/GHSFMTask.java

@ -34,6 +34,7 @@ import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.nl.wms.util.TaskUtils; import org.nl.wms.util.TaskUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -49,6 +50,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("GHSFMTask") @TaskType("GHSFMTask")
@Lazy
public class GHSFMTask extends AbstractTask { public class GHSFMTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "GHSFMTask"; private static String TASK_CONFIG_CODE = "GHSFMTask";
/** /**

2
lms/nladmin-system/nlsso-server/src/main/java/org/nl/wms/sch/task_manage/task/tasks/ghs/GHSQHTask.java

@ -31,6 +31,7 @@ import org.nl.wms.sch.task_manage.task.core.TaskStatus;
import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper; import org.nl.wms.sch.task_manage.task.tasks.mapper.PointMapper;
import org.nl.wms.util.PointUtils; import org.nl.wms.util.PointUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -46,6 +47,7 @@ import java.util.stream.Collectors;
@Slf4j @Slf4j
@Component @Component
@TaskType("GHSQHTask") @TaskType("GHSQHTask")
@Lazy
public class GHSQHTask extends AbstractTask { public class GHSQHTask extends AbstractTask {
private static String TASK_CONFIG_CODE = "GHSQHTask"; private static String TASK_CONFIG_CODE = "GHSQHTask";
/** /**

Loading…
Cancel
Save