Commit 18d4412c by 丁伟峰

Merge remote-tracking branch 'origin/develop' into develop

2 parents 398ccd2c 9d9f09a9
......@@ -13,7 +13,7 @@ public class OrderAppointment {
private String engineerCode;
private String engineerName;
private String engineerPhone;
private String engineerAge;
private Integer engineerAge;
private Integer isWorkshop;
private Timestamp expectStartTime;
private Timestamp expectEndTime;
......
......@@ -220,8 +220,6 @@ public class DispatchServiceImpl implements DispatchService {
OrderRequestScheduler scheduler = new OrderRequestScheduler();
List<LineSegment> results = scheduler.scheduler(orders, orderAppointments);
System.out.println(results);
for (LineSegment r : results) {
String orderId = r.id;
......@@ -234,13 +232,13 @@ public class DispatchServiceImpl implements DispatchService {
op.setMainSub(1);
op.setEngineerCode(engineerCode);
op.setEngineerName(engineer.getName());
op.setEngineerAge("");
op.setEngineerAge(0);
op.setEngineerPhone(engineer.getPhone());
op.setIsWorkshop(0);
op.setExpectStartTime(expectStartTime);
op.setExpectStartTime(expectEndTime);
op.setExpectEndTime(expectEndTime);
op.setPreStatus("PRE");
op.setStatus("PRE");
op.setStatus("ASSIGNED");
orderAppointmentMPDao.insert(op);
......@@ -485,10 +483,18 @@ class OrderRequestScheduler {
List<Line> newTasks = new ArrayList<>();
for (OrderRequest o : orderRequests) {
if (!o.getAppointmentStatus().equals("NOT_ASSIGNED")) {
continue;
}
Line t = new Line(o.getOrderId(), 30);
newTasks.add(t);
}
if (newTasks.isEmpty()) {
List<LineSegment> empty = new ArrayList<>();
return empty;
}
LineSegmentScheduler scheduler = new LineSegmentScheduler();
return scheduler.scheduleLineSegments(used, newTasks);
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!