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 a81bbd7f
authored
Dec 06, 2023
by
huangjinxin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:小组数据同步优化
1 parent
ecbf6aa3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
0 deletions
project-order/src/main/java/com/dituhui/pea/order/feign/bean/enums/BeanOrgLevelEnum.java
project-order/src/main/java/com/dituhui/pea/order/service/impl/BeanRemoteServiceImpl.java
project-order/src/main/java/com/dituhui/pea/order/service/impl/FendanServiceImpl.java
project-order/src/main/java/com/dituhui/pea/order/service/impl/OrderInfoServiceImpl.java
project-order/src/main/java/com/dituhui/pea/order/feign/bean/enums/BeanOrgLevelEnum.java
View file @
a81bbd7
...
@@ -22,6 +22,8 @@ public enum BeanOrgLevelEnum implements IResult {
...
@@ -22,6 +22,8 @@ public enum BeanOrgLevelEnum implements IResult {
STATION
(
"STATION"
,
"分站"
),
STATION
(
"STATION"
,
"分站"
),
GROUP
(
"GROUP"
,
"小组"
),
PERIPHERY
(
"PERIPHERY"
,
"外围"
),
PERIPHERY
(
"PERIPHERY"
,
"外围"
),
REPAIR_CENTER
(
"REPAIR_CENTER"
,
"寄修中心"
),
REPAIR_CENTER
(
"REPAIR_CENTER"
,
"寄修中心"
),
...
...
project-order/src/main/java/com/dituhui/pea/order/service/impl/BeanRemoteServiceImpl.java
View file @
a81bbd7
...
@@ -495,6 +495,9 @@ public class BeanRemoteServiceImpl {
...
@@ -495,6 +495,9 @@ public class BeanRemoteServiceImpl {
if
(
data
.
getDeptType
().
equals
(
BeanOrgLevelEnum
.
STATION
.
getCode
()))
{
if
(
data
.
getDeptType
().
equals
(
BeanOrgLevelEnum
.
STATION
.
getCode
()))
{
groupEntity
.
setKind
(
1
);
groupEntity
.
setKind
(
1
);
}
}
if
(
data
.
getDeptType
().
equals
(
BeanOrgLevelEnum
.
GROUP
.
getCode
()))
{
groupEntity
.
setKind
(
3
);
}
groupEntity
.
setCategory
(
1
);
groupEntity
.
setCategory
(
1
);
groupEntity
.
setBsDeptId
(
data
.
getBsDeptId
());
groupEntity
.
setBsDeptId
(
data
.
getBsDeptId
());
orgGroupDao
.
save
(
groupEntity
);
orgGroupDao
.
save
(
groupEntity
);
...
...
project-order/src/main/java/com/dituhui/pea/order/service/impl/FendanServiceImpl.java
View file @
a81bbd7
...
@@ -273,6 +273,9 @@ public class FendanServiceImpl implements FendanService {
...
@@ -273,6 +273,9 @@ public class FendanServiceImpl implements FendanService {
List
<
OrgTeamEntity
>
teamList
=
orgTeamDao
.
findByTeamIdIn
(
teamIdList
);
List
<
OrgTeamEntity
>
teamList
=
orgTeamDao
.
findByTeamIdIn
(
teamIdList
);
Map
<
String
,
OrgTeamEntity
>
teamMap
=
teamList
.
stream
().
collect
(
Collectors
.
toMap
(
OrgTeamEntity:
:
getTeamId
,
e
->
e
));
Map
<
String
,
OrgTeamEntity
>
teamMap
=
teamList
.
stream
().
collect
(
Collectors
.
toMap
(
OrgTeamEntity:
:
getTeamId
,
e
->
e
));
List
<
OrgGroupEntity
>
orgGroupList
=
orgGroupDao
.
findByTeamIdIn
(
teamIdList
);
List
<
OrgGroupEntity
>
orgGroupList
=
orgGroupDao
.
findByTeamIdIn
(
teamIdList
);
if
(
CollectionUtils
.
isEmpty
(
orgGroupList
))
{
return
Result
.
failed
(
StatusCodeEnum
.
FENDAN_TEAM_UNMATCHED
);
}
for
(
OrgGroupEntity
orgGroupEntity
:
orgGroupList
)
{
for
(
OrgGroupEntity
orgGroupEntity
:
orgGroupList
)
{
OrgGroupInfo
orgGroup
=
BeanUtil
.
copyProperties
(
orgGroupEntity
,
OrgGroupInfo
.
class
);
OrgGroupInfo
orgGroup
=
BeanUtil
.
copyProperties
(
orgGroupEntity
,
OrgGroupInfo
.
class
);
MapBlockInfoEntity
allLayer
=
null
;
MapBlockInfoEntity
allLayer
=
null
;
...
...
project-order/src/main/java/com/dituhui/pea/order/service/impl/OrderInfoServiceImpl.java
View file @
a81bbd7
...
@@ -170,6 +170,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
...
@@ -170,6 +170,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
@Override
@Override
@Transactional
@Transactional
public
Result
<?>
orderStageChanged
(
OrderDTO
.
StageChangeRequest
request
)
{
public
Result
<?>
orderStageChanged
(
OrderDTO
.
StageChangeRequest
request
)
{
log
.
info
(
"[orderStageChanged] orderId:{}, req: {}"
,
request
.
getOrderId
(),
JSONObject
.
toJSONString
(
request
));
final
String
orderId
=
request
.
getOrderId
();
final
String
orderId
=
request
.
getOrderId
();
OrderInfoEntity
orderInfo
=
orderInfoDao
.
getByOrderId
(
orderId
);
OrderInfoEntity
orderInfo
=
orderInfoDao
.
getByOrderId
(
orderId
);
//判断是否是正常流程,正常流程只需要更新状态
//判断是否是正常流程,正常流程只需要更新状态
...
@@ -249,6 +250,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
...
@@ -249,6 +250,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
return
this
.
orderReschedule
(
reschedule
);
return
this
.
orderReschedule
(
reschedule
);
}
}
log
.
info
(
"[orderStageChanged] orderId:{}, 操作成功"
,
request
.
getOrderId
());
return
Result
.
success
(
null
);
return
Result
.
success
(
null
);
}
}
...
@@ -485,6 +487,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
...
@@ -485,6 +487,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
// 登记事件
// 登记事件
commonService
.
addOrderEvent
(
req
.
getOrderId
(),
""
,
req
.
getOperator
(),
req
.
getOperator
(),
OrderEventEnum
.
recontracting
.
getEvent
(),
String
.
format
(
OrderEventEnum
.
recontracting
.
getMsg
(),
engineerName
+
"-"
+
(
ObjectUtil
.
isNotNull
(
orgTeamEntity
)
?
orgTeamEntity
.
getTeamName
()
:
""
),
ObjectUtil
.
isNotNull
(
orgGroupEntity
)
?
orgGroupEntity
.
getGroupName
()
:
""
,
req
.
getExpectBegin
(),
req
.
getReschedulingReason
()),
StringUtils
.
isNotBlank
(
req
.
getReschedulingReason
())
?
"改约原因:"
+
req
.
getReschedulingReason
()
:
""
);
commonService
.
addOrderEvent
(
req
.
getOrderId
(),
""
,
req
.
getOperator
(),
req
.
getOperator
(),
OrderEventEnum
.
recontracting
.
getEvent
(),
String
.
format
(
OrderEventEnum
.
recontracting
.
getMsg
(),
engineerName
+
"-"
+
(
ObjectUtil
.
isNotNull
(
orgTeamEntity
)
?
orgTeamEntity
.
getTeamName
()
:
""
),
ObjectUtil
.
isNotNull
(
orgGroupEntity
)
?
orgGroupEntity
.
getGroupName
()
:
""
,
req
.
getExpectBegin
(),
req
.
getReschedulingReason
()),
StringUtils
.
isNotBlank
(
req
.
getReschedulingReason
())
?
"改约原因:"
+
req
.
getReschedulingReason
()
:
""
);
log
.
info
(
"[orderReschedule] orderId:{}, 操作成功"
,
req
.
getOrderId
());
return
Result
.
success
(
null
);
return
Result
.
success
(
null
);
}
}
...
...
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