Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
ab810006
提交
ab810006
authored
9月 07, 2021
作者:
133
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix(维修模块): 修改维修模块bug
提交本次维修撤回bug Closes
#8
上级
5efe52bf
显示空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
6 行增加
和
5 行删除
+6
-5
RepairController.java
...m/tykj/dev/device/repair/controller/RepairController.java
+6
-5
没有找到文件。
dev-repair/src/main/java/com/tykj/dev/device/repair/controller/RepairController.java
浏览文件 @
ab810006
...
@@ -2294,9 +2294,6 @@ public class RepairController {
...
@@ -2294,9 +2294,6 @@ public class RepairController {
String
currentUserUnitName
=
userUtils
.
getCurrentUserUnitName
();
String
currentUserUnitName
=
userUtils
.
getCurrentUserUnitName
();
//查询维修详情
//查询维修详情
List
<
RepairDetail
>
byDeviceRepairBillId
=
repairDetailDao
.
findByDeviceRepairBillId
(
repairBill
.
getId
());
List
<
RepairDetail
>
byDeviceRepairBillId
=
repairDetailDao
.
findByDeviceRepairBillId
(
repairBill
.
getId
());
//进行过滤
// List<RepairDetail> repairDetails = byDeviceRepairBillId.stream().filter(repairDetail -> repairDetail.getRepairBackBillId() == null && repairDetail.getRepairStatus().equals(RepairStatusEnum.WAIT_REPAIR.id) && repairDetail.getLocationUnit().equals(repairDetail.getOwnUnit()))
// .collect(Collectors.toList());
List
<
RepairDetail
>
repairDetails
=
byDeviceRepairBillId
.
stream
().
filter
(
repairDetail
->
{
List
<
RepairDetail
>
repairDetails
=
byDeviceRepairBillId
.
stream
().
filter
(
repairDetail
->
{
if
(!
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
()))
{
if
(!
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
()))
{
return
repairDetail
.
getRepairBackBillId
()
==
null
&&
repairDetail
.
getRepairStatus
().
equals
(
RepairStatusEnum
.
WAIT_REPAIR
.
id
)
&&
repairDetail
.
getLocationUnit
().
equals
(
currentUserUnitName
);
return
repairDetail
.
getRepairBackBillId
()
==
null
&&
repairDetail
.
getRepairStatus
().
equals
(
RepairStatusEnum
.
WAIT_REPAIR
.
id
)
&&
repairDetail
.
getLocationUnit
().
equals
(
currentUserUnitName
);
...
@@ -2305,9 +2302,11 @@ public class RepairController {
...
@@ -2305,9 +2302,11 @@ public class RepairController {
}
}
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
repairDetails
.
forEach
(
repairDetail
->
{
repairDetails
.
forEach
(
repairDetail
->
{
if
(
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
())){
repairDetail
.
setDeviceRepairBillId
(
0
);
repairDetail
.
setDeviceRepairBillId
(
0
);
}
repairDetail
.
setRepairStatus
(
RepairStatusEnum
.
WAIT_SEND
.
id
);
repairDetail
.
setRepairStatus
(
RepairStatusEnum
.
WAIT_SEND
.
id
);
repairDetail
.
setLocationUnit
(
repairDetail
.
getOwnUnit
());
repairDetailDao
.
save
(
repairDetail
);
repairDetailDao
.
save
(
repairDetail
);
});
});
//直接删除维修单
//直接删除维修单
...
@@ -2380,9 +2379,11 @@ public class RepairController {
...
@@ -2380,9 +2379,11 @@ public class RepairController {
List
<
RepairDetail
>
repairDetails
=
byRepairBackBillId
.
stream
().
filter
(
repairDetail
->
repairDetail
.
getDeviceRepairBillId
()
!=
null
&&
!
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
())
&&
repairDetail
.
getRepairStatus
().
equals
(
RepairStatusEnum
.
RECEIVE_WAIT_STORAGE
.
id
)
&&
repairDetail
.
getLocationUnit
().
equals
(
currentUserUnitName
))
List
<
RepairDetail
>
repairDetails
=
byRepairBackBillId
.
stream
().
filter
(
repairDetail
->
repairDetail
.
getDeviceRepairBillId
()
!=
null
&&
!
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
())
&&
repairDetail
.
getRepairStatus
().
equals
(
RepairStatusEnum
.
RECEIVE_WAIT_STORAGE
.
id
)
&&
repairDetail
.
getLocationUnit
().
equals
(
currentUserUnitName
))
.
collect
(
Collectors
.
toList
());
.
collect
(
Collectors
.
toList
());
for
(
RepairDetail
repairDetail
:
repairDetails
)
{
for
(
RepairDetail
repairDetail
:
repairDetails
)
{
if
(!
repairDetail
.
getLocationUnit
().
equals
(
repairDetail
.
getOwnUnit
())){
repairDetail
.
setRepairBackBillId
(
0
);
repairDetail
.
setRepairBackBillId
(
0
);
}
repairDetail
.
setRepairStatus
(
2
);
repairDetail
.
setRepairStatus
(
2
);
repairDetail
.
setLocationUnit
(
repairDetail
.
getOwnUnit
());
//
repairDetail.setLocationUnit(repairDetail.getOwnUnit());
repairDetailDao
.
save
(
repairDetail
);
repairDetailDao
.
save
(
repairDetail
);
}
}
//删除账单
//删除账单
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论