Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
yangxiujun
/
paidan_demo
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 18d4412c
authored
Jun 15, 2023
by
丁伟峰
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop' into develop
2 parents
398ccd2c
9d9f09a9
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
6 deletions
project-order/src/main/java/com/alibaba/cloud/integration/order/entity/OrderAppointment.java
project-order/src/main/java/com/alibaba/cloud/integration/order/service/impl/DispatchServiceImpl.java
project-order/src/main/java/com/alibaba/cloud/integration/order/entity/OrderAppointment.java
View file @
18d4412
...
...
@@ -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
;
...
...
project-order/src/main/java/com/alibaba/cloud/integration/order/service/impl/DispatchServiceImpl.java
View file @
18d4412
...
...
@@ -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
.
setExpect
Start
Time
(
expectEndTime
);
op
.
setExpect
End
Time
(
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
);
}
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment