Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
81f8d9fe
提交
81f8d9fe
authored
11月 12, 2021
作者:
zjm
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix(丢失、找回、清退): 阅知格式的修改
阅知格式的修改
上级
0c601c1b
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
53 行增加
和
16 行删除
+53
-16
LossBillServiceImpl.java
...ykj/dev/device/loss/service/impl/LossBillServiceImpl.java
+24
-11
MessageFormatUtil.java
.../main/java/com/tykj/dev/misc/utils/MessageFormatUtil.java
+9
-0
RepelBusinessServiceImpl.java
...evice/sendback/service/impl/RepelBusinessServiceImpl.java
+20
-5
没有找到文件。
dev-loss/src/main/java/com/tykj/dev/device/loss/service/impl/LossBillServiceImpl.java
浏览文件 @
81f8d9fe
package
com
.
tykj
.
dev
.
device
.
loss
.
service
.
impl
;
package
com
.
tykj
.
dev
.
device
.
loss
.
service
.
impl
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.tykj.dev.blockcha.subject.service.BlockChainUtil
;
import
com.tykj.dev.blockcha.subject.service.BlockChainUtil
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.config.base.FileName
;
import
com.tykj.dev.config.base.FileName
;
...
@@ -10,6 +11,7 @@ import com.tykj.dev.device.library.service.DeviceLibraryService;
...
@@ -10,6 +11,7 @@ import com.tykj.dev.device.library.service.DeviceLibraryService;
import
com.tykj.dev.device.library.service.DeviceLogService
;
import
com.tykj.dev.device.library.service.DeviceLogService
;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.vo.ScriptSaveVo
;
import
com.tykj.dev.device.loss.entity.domain.DeviceLoss
;
import
com.tykj.dev.device.loss.entity.domain.DeviceLoss
;
import
com.tykj.dev.device.loss.entity.vo.LossAuditvo
;
import
com.tykj.dev.device.loss.entity.vo.LossAuditvo
;
import
com.tykj.dev.device.loss.entity.vo.RetrieveAuditvo
;
import
com.tykj.dev.device.loss.entity.vo.RetrieveAuditvo
;
...
@@ -31,15 +33,15 @@ import com.tykj.dev.device.user.subject.service.UserService;
...
@@ -31,15 +33,15 @@ import com.tykj.dev.device.user.subject.service.UserService;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.BusinessEnum
;
//import com.tykj.dev.misc.base.DeviceLifeStatus;
//import com.tykj.dev.misc.base.DeviceLifeStatus;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.MessageFormatUtil
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.atomic.AtomicInteger
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -102,13 +104,24 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -102,13 +104,24 @@ public class LossBillServiceImpl implements LossBillService {
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
taskBto
=
newLossCountyTask
(
parentUnits
.
getUnitId
(),
deviceLossThis
.
getId
(),
units
.
getName
()
+
"丢失装备任务"
,
securityUser
.
getCurrentUserInfo
().
getUserId
());
taskBto
=
newLossCountyTask
(
parentUnits
.
getUnitId
(),
deviceLossThis
.
getId
(),
units
.
getName
()
+
"丢失装备任务"
,
securityUser
.
getCurrentUserInfo
().
getUserId
());
}
}
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起
了装备丢失"
,
gainThisUser
(
securityUser
.
getCurrentUserInfo
().
getUserId
(),
securityUser
.
getCurrentUserInfo
().
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起
装备丢失:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
gainThisUser
(
securityUser
.
getCurrentUserInfo
().
getUserId
(),
securityUser
.
getCurrentUserInfo
().
getUnitsId
())));
deviceLibraryService
.
upDateLeftStatus
(
DeviceLifeStatus
.
LOSS
.
id
,
deviceLoss
.
getDevIdsList
());
deviceLibraryService
.
upDateLeftStatus
(
DeviceLifeStatus
.
LOSS
.
id
,
deviceLoss
.
getDevIdsList
());
devLogAdd
(
deviceLoss
.
getDevIdsList
(),
"装备报备丢失"
,
deviceLoss
.
getCreateUserId
(),
taskBto
.
getId
());
devLogAdd
(
deviceLoss
.
getDevIdsList
(),
"装备报备丢失"
,
deviceLoss
.
getCreateUserId
(),
taskBto
.
getId
());
}
}
private
String
toMessageCount
(
String
json
){
List
<
Integer
>
ids
=
StringUtils
.
stringToList
(
json
);
Set
<
String
>
strings
=
new
HashSet
<>();
deviceLibraryService
.
findByIds
(
ids
).
forEach
(
deviceLibrary
->
{
strings
.
add
(
deviceLibrary
.
getModel
());
}
);
return
MessageFormatUtil
.
spellModelSetAndCount
(
strings
,
ids
.
size
());
}
@Override
@Override
public
void
superiorAuditLoss
(
LossAuditvo
lossAuditvo
)
{
public
void
superiorAuditLoss
(
LossAuditvo
lossAuditvo
)
{
...
@@ -132,7 +145,7 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -132,7 +145,7 @@ public class LossBillServiceImpl implements LossBillService {
taskBto
.
setOwnUnit
(
parentUnits
.
getUnitId
());
taskBto
.
setOwnUnit
(
parentUnits
.
getUnitId
());
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
LOSS1301
,
0
);
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
LOSS1301
,
0
);
}
}
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"审核
了装备丢失业务"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"审核
装备丢失:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
deviceLossService
.
save
(
deviceLoss
);
deviceLossService
.
save
(
deviceLoss
);
}
}
...
@@ -156,7 +169,7 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -156,7 +169,7 @@ public class LossBillServiceImpl implements LossBillService {
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
taskBto
=
newRetrieveCountyTask
(
parentUnits
.
getUnitId
(),
deviceLossThis
.
getId
(),
units
.
getName
()
+
"找回装备任务"
,
securityUser
.
getCurrentUserInfo
().
getUserId
());
taskBto
=
newRetrieveCountyTask
(
parentUnits
.
getUnitId
(),
deviceLossThis
.
getId
(),
units
.
getName
()
+
"找回装备任务"
,
securityUser
.
getCurrentUserInfo
().
getUserId
());
}
}
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起
装备找回业务"
,
gainThisUser
(
securityUser
.
getCurrentUserInfo
().
getUserId
(),
securityUser
.
getCurrentUserInfo
().
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起
装备找回"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
gainThisUser
(
securityUser
.
getCurrentUserInfo
().
getUserId
(),
securityUser
.
getCurrentUserInfo
().
getUnitsId
())));
devLogAdd
(
deviceLoss
.
getDevIdsList
(),
"装备找回上报"
,
deviceLoss
.
getCreateUserId
(),
taskBto
.
getId
());
devLogAdd
(
deviceLoss
.
getDevIdsList
(),
"装备找回上报"
,
deviceLoss
.
getCreateUserId
(),
taskBto
.
getId
());
}
}
...
@@ -175,11 +188,11 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -175,11 +188,11 @@ public class LossBillServiceImpl implements LossBillService {
taskService
.
moveToEnd
(
taskBto
);
taskService
.
moveToEnd
(
taskBto
);
deviceLoss
.
setBackStatus
(
2
);
deviceLoss
.
setBackStatus
(
2
);
deviceLibraryService
.
upDateLeftStatus
(
DeviceLifeStatus
.
IN_LIBRARY
.
id
,
StringUtils
.
stringToList
(
deviceLoss
.
getDevIds
()));
deviceLibraryService
.
upDateLeftStatus
(
DeviceLifeStatus
.
IN_LIBRARY
.
id
,
StringUtils
.
stringToList
(
deviceLoss
.
getDevIds
()));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
装备找回业务审核成功"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
审核通过 装备找回:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
}
else
{
}
else
{
taskService
.
moveToEnd
(
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1403
));
taskService
.
moveToEnd
(
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1403
));
User
user1
=
userService
.
findByUser
(
taskBto
.
getCreateUserId
());
User
user1
=
userService
.
findByUser
(
taskBto
.
getCreateUserId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
装备找回业务审核不通过"
,
findUnitId
(
user1
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
审核不通过 装备找回:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
findUnitId
(
user1
.
getUnitsId
())));
deviceLoss
.
setBackStatus
(
3
);
deviceLoss
.
setBackStatus
(
3
);
}
}
}
else
{
}
else
{
...
@@ -190,12 +203,12 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -190,12 +203,12 @@ public class LossBillServiceImpl implements LossBillService {
if
(
retrieveAuditvo
.
getType
()==
1
){
if
(
retrieveAuditvo
.
getType
()==
1
){
taskBto
.
setOwnUnit
(
parentUnits
.
getUnitId
());
taskBto
.
setOwnUnit
(
parentUnits
.
getUnitId
());
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1401
,
0
);
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1401
,
0
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
装备找回业务审核成功"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
审核通过 装备找回:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
}
else
{
}
else
{
taskService
.
moveToEnd
(
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1402
));
taskService
.
moveToEnd
(
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
RETRIEVE1402
));
deviceLoss
.
setBackStatus
(
3
);
deviceLoss
.
setBackStatus
(
3
);
User
user1
=
userService
.
findByUser
(
taskBto
.
getCreateUserId
());
User
user1
=
userService
.
findByUser
(
taskBto
.
getCreateUserId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
装备找回业务审核不通过"
,
findUnitId
(
user1
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
审核不通过 装备找回:"
+
toMessageCount
(
deviceLoss
.
getDevIds
())
,
findUnitId
(
user1
.
getUnitsId
())));
}
}
}
}
...
...
dev-misc/src/main/java/com/tykj/dev/misc/utils/MessageFormatUtil.java
浏览文件 @
81f8d9fe
...
@@ -42,6 +42,15 @@ public class MessageFormatUtil {
...
@@ -42,6 +42,15 @@ public class MessageFormatUtil {
}
}
/**
* 阅知中拼接型号和数量
*/
public
static
String
spellModelSetAndCount
(
Set
<
String
>
models
,
Integer
count
)
{
return
"【型号:"
+
String
.
join
(
","
,
models
)
+
"共"
+
count
+
"件装备】"
;
}
/**
/**
* 一个【】填空内容的通用接口
* 一个【】填空内容的通用接口
*/
*/
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/impl/RepelBusinessServiceImpl.java
浏览文件 @
81f8d9fe
...
@@ -47,6 +47,7 @@ import java.time.LocalDateTime;
...
@@ -47,6 +47,7 @@ import java.time.LocalDateTime;
import
java.util.*
;
import
java.util.*
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.atomic.AtomicBoolean
;
import
java.util.concurrent.atomic.AtomicBoolean
;
import
java.util.concurrent.atomic.AtomicInteger
;
import
java.util.concurrent.atomic.AtomicReference
;
import
java.util.concurrent.atomic.AtomicReference
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -643,7 +644,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
...
@@ -643,7 +644,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
deviceRepelDetail
.
setRepelId
(
deviceRepel1
.
getId
());
deviceRepelDetail
.
setRepelId
(
deviceRepel1
.
getId
());
deviceRepelDetail
.
setRepelStatus
(
1
);
deviceRepelDetail
.
setRepelStatus
(
1
);
TaskBto
taskBto
=
cityInitiateTask
(
unitsFather
.
getUnitId
(),
deviceRepel1
.
getId
(),
deviceRepel
.
getTitle
(),
userId
);
TaskBto
taskBto
=
cityInitiateTask
(
unitsFather
.
getUnitId
(),
deviceRepel1
.
getId
(),
deviceRepel
.
getTitle
(),
userId
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
user
.
getName
()
+
"发起清退任务["
+
deviceRepel1
.
getTitle
()
+
"]"
,
gainThisUser
(
userId
,
units
.
getUnitId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起 清退出库:"
+
toMessageCount
(
deviceRepelDetail
.
getScriptJson
(),
deviceRepelDetail
.
getSendUnit
())
,
gainThisUser
(
userId
,
units
.
getUnitId
())));
}
}
...
@@ -850,7 +851,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
...
@@ -850,7 +851,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
SEND_BACK_1209
,
0
);
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
SEND_BACK_1209
,
0
);
DeviceRepel
deviceRepel
=
deviceRepelService
.
findDeviceRepel
(
deviceRepelDetail
.
getRepelId
());
DeviceRepel
deviceRepel
=
deviceRepelService
.
findDeviceRepel
(
deviceRepelDetail
.
getRepelId
());
waitingReceiptsTask
(
orderOutData
.
getSendUnitId
(),
deviceRepelDetail
.
getId
(),
taskBto
.
getId
(),
taskBto
.
getTitle
(),
userId
);
waitingReceiptsTask
(
orderOutData
.
getSendUnitId
(),
deviceRepelDetail
.
getId
(),
taskBto
.
getId
(),
taskBto
.
getTitle
(),
userId
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
清退设备出库完成"
,
gainThisUser
(
userId
,
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
发起 清退出库:"
+
toMessageCount
(
deviceRepelDetail
.
getScriptJson
(),
deviceRepelDetail
.
getSendUnit
())
,
gainThisUser
(
userId
,
user
.
getUnitsId
())));
devLogAdd
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()),
deviceRepelDetail
.
getSendUnit
()
+
"装备清退出库"
+
",等待接收"
,
userId
,
taskBto
.
getId
());
devLogAdd
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()),
deviceRepelDetail
.
getSendUnit
()
+
"装备清退出库"
+
",等待接收"
,
userId
,
taskBto
.
getId
());
orderOutDataRepelDetail
.
setDeviceLibraryEntities
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()));
orderOutDataRepelDetail
.
setDeviceLibraryEntities
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()));
//把一些字段填写到对象中,保存入库
//把一些字段填写到对象中,保存入库
...
@@ -1009,7 +1010,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
...
@@ -1009,7 +1010,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
taskService
.
moveToEnd
(
taskService
.
findBillTypeAndFatherId
(
BusinessEnum
.
SEND_BACK
.
id
,
taskId
));
taskService
.
moveToEnd
(
taskService
.
findBillTypeAndFatherId
(
BusinessEnum
.
SEND_BACK
.
id
,
taskId
));
taskService
.
moveToArchive
(
taskService
.
findBillTypeAndFatherId
(
BusinessEnum
.
SEND_BACK
.
id
,
taskId
));
taskService
.
moveToArchive
(
taskService
.
findBillTypeAndFatherId
(
BusinessEnum
.
SEND_BACK
.
id
,
taskId
));
devLogAdd
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()),
"签收"
+
deviceRepelDetail
.
getSendUnit
()
+
"清退的设备"
,
storageDeviceRepel
.
getUserId
(),
taskBto
.
getId
());
devLogAdd
(
findInvoleDevice
(
deviceRepelDetail
.
getDeviceIds
()),
"签收"
+
deviceRepelDetail
.
getSendUnit
()
+
"清退的设备"
,
storageDeviceRepel
.
getUserId
(),
taskBto
.
getId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
签收"
+
deviceRepelDetail
.
getSendUnit
()
+
"清退的设备"
,
findUnitIds
(
user
.
getUserId
(),
unitIds
)));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
办结 清退业务:"
+
toMessageCount
(
deviceRepelDetail
.
getScriptJson
(),
deviceRepelDetail
.
getSendUnit
())
,
findUnitIds
(
user
.
getUserId
(),
unitIds
)));
}
else
{
}
else
{
if
(
storageDeviceRepel
.
getIsIgnore
()
==
null
)
{
if
(
storageDeviceRepel
.
getIsIgnore
()
==
null
)
{
List
<
StatusEnum
>
enumList
=
new
ArrayList
<>();
List
<
StatusEnum
>
enumList
=
new
ArrayList
<>();
...
@@ -1047,7 +1048,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
...
@@ -1047,7 +1048,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
FileRet
fileRet
=
pdfService
.
billPdf
(
documents
);
FileRet
fileRet
=
pdfService
.
billPdf
(
documents
);
deviceRepelDetail
.
setOutboundFile
(
JacksonUtil
.
toJSon
(
fileRet
));
deviceRepelDetail
.
setOutboundFile
(
JacksonUtil
.
toJSon
(
fileRet
));
deviceRepelDetail
.
setSendFiles
(
JacksonUtil
.
toJSon
(
fileRet
));
deviceRepelDetail
.
setSendFiles
(
JacksonUtil
.
toJSon
(
fileRet
));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
签收"
+
deviceRepelDetail
.
getSendUnit
()
+
"清退的设备"
,
findUnitIds
(
user
.
getUserId
(),
unitIds
)));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"
接收 清退业务:"
+
toMessageCount
(
deviceRepelDetail
.
getScriptJson
(),
deviceRepelDetail
.
getSendUnit
())
,
findUnitIds
(
user
.
getUserId
(),
unitIds
)));
}
}
}
}
deviceRepelDetail
.
setReceiveTime
(
new
Date
());
deviceRepelDetail
.
setReceiveTime
(
new
Date
());
...
@@ -1197,7 +1198,21 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
...
@@ -1197,7 +1198,21 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
List
<
Integer
>
unitIds
=
new
ArrayList
<>();
List
<
Integer
>
unitIds
=
new
ArrayList
<>();
unitIds
.
add
(
deviceRepelDetail
.
getSendUnitId
());
unitIds
.
add
(
deviceRepelDetail
.
getSendUnitId
());
unitIds
.
add
(
deviceRepelDetail
.
getReceiveUnitId
());
unitIds
.
add
(
deviceRepelDetail
.
getReceiveUnitId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"装备清退任务,出库方上传了回执单据任务结束"
,
findUnitIds
(
storageDeviceRepel
.
getUserId
(),
unitIds
)));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"办结 清退业务:"
+
toMessageCount
(
deviceRepelDetail
.
getScriptJson
(),
deviceRepelDetail
.
getSendUnit
()),
findUnitIds
(
storageDeviceRepel
.
getUserId
(),
unitIds
)));
}
private
String
toMessageCount
(
String
json
,
String
unitName
){
List
<
ScriptSaveVo
>
scriptSaveVoList
=
JacksonUtil
.
readValue
(
json
,
new
TypeReference
<
List
<
ScriptSaveVo
>>()
{
});
Set
<
String
>
strings
=
new
HashSet
<>();
AtomicInteger
count
=
new
AtomicInteger
();
scriptSaveVoList
.
forEach
(
scriptSaveVo
->
{
strings
.
add
(
scriptSaveVo
.
getModel
());
count
.
set
(
count
.
get
()
+
scriptSaveVo
.
getNum
());
}
);
return
MessageFormatUtil
.
spellUnitAndModelAndCount
(
unitName
,
strings
,
count
.
get
());
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论