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 78b37697
authored
Dec 04, 2023
by
huangjinxin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:工作队工程师关联关系处理
1 parent
4315a6f4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
project-order/src/main/java/com/dituhui/pea/order/service/impl/BusinessTeamServiceImpl.java
project-order/src/main/java/com/dituhui/pea/order/service/impl/BusinessTeamServiceImpl.java
View file @
78b3769
package
com
.
dituhui
.
pea
.
order
.
service
.
impl
;
import
cn.hutool.core.util.IdUtil
;
import
cn.hutool.core.util.ObjectUtil
;
import
com.dituhui.pea.common.BusinessException
;
import
com.dituhui.pea.common.Result
;
import
com.dituhui.pea.order.common.DateUtils
;
...
...
@@ -17,10 +18,7 @@ import com.dituhui.pea.order.dto.BusinessTeamDetailDTO;
import
com.dituhui.pea.order.dto.BusinessTeamUpdateDTO
;
import
com.dituhui.pea.order.dto.BusinessTeamWarehousesDTO
;
import
com.dituhui.pea.order.dto.BusinessTeamsDTO
;
import
com.dituhui.pea.order.entity.OrgGroupEntity
;
import
com.dituhui.pea.order.entity.OrgTeamEngineerEntity
;
import
com.dituhui.pea.order.entity.OrgTeamEntity
;
import
com.dituhui.pea.order.entity.OrgWarehouseInfoEntity
;
import
com.dituhui.pea.order.entity.*
;
import
com.dituhui.pea.order.service.BusinessTeamService
;
import
com.dituhui.pea.order.service.CommonService
;
import
lombok.extern.slf4j.Slf4j
;
...
...
@@ -81,9 +79,14 @@ public class BusinessTeamServiceImpl implements BusinessTeamService {
page
=
orgTeamDao
.
findAllByGroupId
(
req
.
getLevelValue
(),
pageable
);
}
for
(
OrgTeamEntity
e
:
page
.
getContent
())
{
List
<
String
>
engineers
=
orgTeamEngineerDao
.
findAllByTeamId
(
e
.
getTeamId
()).
stream
().
map
(
e2
->
{
return
engineerInfoDao
.
getByEngineerCode
(
e2
.
getEngineerCode
()).
getName
();
}).
collect
(
Collectors
.
toList
());
List
<
String
>
engineers
=
new
ArrayList
<>();
for
(
OrgTeamEngineerEntity
e2
:
orgTeamEngineerDao
.
findAllByTeamId
(
e
.
getTeamId
()))
{
EngineerInfoEntity
infoEntity
=
engineerInfoDao
.
getByEngineerCode
(
e2
.
getEngineerCode
());
if
(
ObjectUtil
.
isNull
(
infoEntity
))
{
continue
;
}
engineers
.
add
(
infoEntity
.
getName
());
}
BusinessTeamsDTO
.
Content
content
=
new
BusinessTeamsDTO
.
Content
();
content
.
setTeamId
(
e
.
getTeamId
()).
setTeamName
(
e
.
getTeamName
());
content
.
setWorkdays
(
String
.
join
(
"、"
,
getWorkdaysChinese
(
e
.
getWorkdays
())));
...
...
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