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 05d7f0ee
authored
Oct 10, 2023
by
chamberone
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' of
https://zhangguoping@gitlab.dituhui.com/bsh/project/pr…
…oject.git into develop
2 parents
7b3aff47
2779f4d0
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
12 deletions
project-order/src/main/java/com/dituhui/pea/order/dto/OrderServiceList.java
project-order/src/main/java/com/dituhui/pea/order/service/impl/OrderServiceListServiceImpl.java
project-order/src/main/java/com/dituhui/pea/order/dto/OrderServiceList.java
View file @
05d7f0e
...
@@ -31,4 +31,11 @@ public class OrderServiceList {
...
@@ -31,4 +31,11 @@ public class OrderServiceList {
private
String
orderStatus
;
private
String
orderStatus
;
private
String
serviceStatus
;
private
String
serviceStatus
;
private
String
createTime
;
private
String
createTime
;
/**
* bean优先级,例如:紧急、正常
*/
private
String
beanPriority
;
}
}
project-order/src/main/java/com/dituhui/pea/order/service/impl/OrderServiceListServiceImpl.java
View file @
05d7f0e
...
@@ -69,7 +69,7 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
...
@@ -69,7 +69,7 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
}
}
}
}
if
(
ListUtils
.
isNotEmpty
(
reqDTO
.
getEngineerCodes
()))
{
if
(
ListUtils
.
isNotEmpty
(
reqDTO
.
getEngineerCodes
()))
{
lqw
.
and
(
w
->
lqw
.
and
(
w
->
w
.
in
(
OrderInfo:
:
getEngineerCode
,
reqDTO
.
getEngineerCodes
())
w
.
in
(
OrderInfo:
:
getEngineerCode
,
reqDTO
.
getEngineerCodes
())
.
or
()
.
or
()
...
@@ -139,6 +139,8 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
...
@@ -139,6 +139,8 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
record
.
setDispatcher
(
o
.
getDispatcher
());
record
.
setDispatcher
(
o
.
getDispatcher
());
record
.
setCreateTime
(
TimeUtils
.
IsoTimestamp2DateTime
(
o
.
getCreateTime
()));
record
.
setCreateTime
(
TimeUtils
.
IsoTimestamp2DateTime
(
o
.
getCreateTime
()));
record
.
setBeanPriority
(
o
.
getBeanPriority
());
content
.
add
(
record
);
content
.
add
(
record
);
}
}
...
@@ -156,42 +158,42 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
...
@@ -156,42 +158,42 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
private
Map
<
String
,
String
>
getEngineerNames
(
List
<
OrderInfo
>
orders
)
{
private
Map
<
String
,
String
>
getEngineerNames
(
List
<
OrderInfo
>
orders
)
{
// 获取技术员姓名
// 获取技术员姓名
Set
<
String
>
engineerCodes
=
new
HashSet
<>();
Set
<
String
>
engineerCodes
=
new
HashSet
<>();
for
(
OrderInfo
r:
orders
)
{
for
(
OrderInfo
r
:
orders
)
{
if
(
StringUtils
.
isNotEmpty
(
r
.
getEngineerCode
()))
{
if
(
StringUtils
.
isNotEmpty
(
r
.
getEngineerCode
()))
{
engineerCodes
.
add
(
r
.
getEngineerCode
());
engineerCodes
.
add
(
r
.
getEngineerCode
());
}
}
if
(
StringUtils
.
isNotEmpty
(
r
.
getEngineerCodeSub
()))
{
if
(
StringUtils
.
isNotEmpty
(
r
.
getEngineerCodeSub
()))
{
engineerCodes
.
add
(
r
.
getEngineerCodeSub
());
engineerCodes
.
add
(
r
.
getEngineerCodeSub
());
}
}
}
}
if
(
engineerCodes
.
isEmpty
())
{
if
(
engineerCodes
.
isEmpty
())
{
return
new
HashMap
<>();
return
new
HashMap
<>();
}
}
List
<
EngineerInfoEntity
>
engineers
=
engineerInfoDao
.
findByEngineerCodeIn
(
new
ArrayList
<>(
engineerCodes
));
List
<
EngineerInfoEntity
>
engineers
=
engineerInfoDao
.
findByEngineerCodeIn
(
new
ArrayList
<>(
engineerCodes
));
return
engineers
.
stream
().
collect
(
Collectors
.
toMap
(
EngineerInfoEntity:
:
getEngineerCode
,
EngineerInfoEntity:
:
getName
));
return
engineers
.
stream
().
collect
(
Collectors
.
toMap
(
EngineerInfoEntity:
:
getEngineerCode
,
EngineerInfoEntity:
:
getName
));
}
}
private
Map
<
String
,
String
>
getBranchNames
(
List
<
OrderInfo
>
orders
)
{
private
Map
<
String
,
String
>
getBranchNames
(
List
<
OrderInfo
>
orders
)
{
// 获取branch名称
// 获取branch名称
Set
<
String
>
branches
=
new
HashSet
<>();
Set
<
String
>
branches
=
new
HashSet
<>();
for
(
OrderInfo
r:
orders
)
{
for
(
OrderInfo
r
:
orders
)
{
if
(
StringUtils
.
isNotEmpty
(
r
.
getOrgBranchId
()))
{
if
(
StringUtils
.
isNotEmpty
(
r
.
getOrgBranchId
()))
{
branches
.
add
(
r
.
getOrgBranchId
());
branches
.
add
(
r
.
getOrgBranchId
());
}
}
}
}
if
(
branches
.
isEmpty
())
{
if
(
branches
.
isEmpty
())
{
return
new
HashMap
<>();
return
new
HashMap
<>();
}
}
List
<
OrgBranchEntity
>
records
=
orgBranchDao
.
findByBranchIdIn
(
new
ArrayList
<>(
branches
));
List
<
OrgBranchEntity
>
records
=
orgBranchDao
.
findByBranchIdIn
(
new
ArrayList
<>(
branches
));
return
records
.
stream
().
collect
(
Collectors
.
toMap
(
OrgBranchEntity:
:
getBranchId
,
OrgBranchEntity:
:
getBranchName
));
return
records
.
stream
().
collect
(
Collectors
.
toMap
(
OrgBranchEntity:
:
getBranchId
,
OrgBranchEntity:
:
getBranchName
));
}
}
private
List
<
String
>
getOrderEngineerNames
(
String
engineerCode
,
String
engineerCodeSub
,
Map
<
String
,
String
>
engineerNames
)
{
private
List
<
String
>
getOrderEngineerNames
(
String
engineerCode
,
String
engineerCodeSub
,
Map
<
String
,
String
>
engineerNames
)
{
// 获取订单技术员姓名信息
// 获取订单技术员姓名信息
List
<
String
>
names
=
new
ArrayList
<>();
List
<
String
>
names
=
new
ArrayList
<>();
for
(
String
code:
List
.
of
(
engineerCode
,
engineerCodeSub
))
{
for
(
String
code
:
List
.
of
(
engineerCode
,
engineerCodeSub
))
{
String
name
=
engineerNames
.
getOrDefault
(
code
,
""
);
String
name
=
engineerNames
.
getOrDefault
(
code
,
""
);
if
(
StringUtils
.
isNotEmpty
(
name
))
{
if
(
StringUtils
.
isNotEmpty
(
name
))
{
names
.
add
(
name
);
names
.
add
(
name
);
}
}
}
}
...
...
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