Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
bd08790d
提交
bd08790d
authored
4月 18, 2023
作者:
zjm
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
工作交接修改提交
上级
82e0d0f1
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
33 行增加
和
1 行删除
+33
-1
HandoverController.java
.../tykj/dev/device/train/controller/HandoverController.java
+11
-0
WorkHandover.java
...n/java/com/tykj/dev/device/train/entity/WorkHandover.java
+1
-1
WorkHandoverService.java
...om/tykj/dev/device/train/service/WorkHandoverService.java
+5
-0
WorkHandoverServiceImpl.java
...ev/device/train/service/impl/WorkHandoverServiceImpl.java
+16
-0
没有找到文件。
dev-train/src/main/java/com/tykj/dev/device/train/controller/HandoverController.java
浏览文件 @
bd08790d
...
@@ -14,6 +14,7 @@ import org.springframework.security.core.annotation.AuthenticationPrincipal;
...
@@ -14,6 +14,7 @@ import org.springframework.security.core.annotation.AuthenticationPrincipal;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
springfox.documentation.annotations.ApiIgnore
;
import
springfox.documentation.annotations.ApiIgnore
;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -82,5 +83,15 @@ public class HandoverController {
...
@@ -82,5 +83,15 @@ public class HandoverController {
return
ResponseEntity
.
ok
(
userService
.
findByUniteId1
(
securityUser
.
getCurrentUserInfo
().
getUnitsId
()).
stream
().
filter
(
userShenRe
->
userShenRe
.
getTrainStatus
()!=
5
).
collect
(
Collectors
.
toList
()));
return
ResponseEntity
.
ok
(
userService
.
findByUniteId1
(
securityUser
.
getCurrentUserInfo
().
getUnitsId
()).
stream
().
filter
(
userShenRe
->
userShenRe
.
getTrainStatus
()!=
5
).
collect
(
Collectors
.
toList
()));
}
}
/**
* 工作交接-终止工作交接
*/
@GetMapping
(
value
=
"/terminateWorkHandover/{billId}"
)
@ApiOperation
(
value
=
"工作交接-终止工作交接"
)
public
ResponseEntity
userList
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@PathVariable
Integer
billId
)
{
workHandoverService
.
terminateWorkHandover
(
billId
);
return
ResponseEntity
.
ok
(
"终止成功"
);
}
}
}
dev-train/src/main/java/com/tykj/dev/device/train/entity/WorkHandover.java
浏览文件 @
bd08790d
...
@@ -62,7 +62,7 @@ public class WorkHandover {
...
@@ -62,7 +62,7 @@ public class WorkHandover {
private
String
file
;
private
String
file
;
/**
/**
* 状态 1.新建 2.完成
* 状态 1.新建 2.完成
3.终止
*/
*/
private
Integer
status
=
1
;
private
Integer
status
=
1
;
...
...
dev-train/src/main/java/com/tykj/dev/device/train/service/WorkHandoverService.java
浏览文件 @
bd08790d
...
@@ -41,4 +41,9 @@ public interface WorkHandoverService {
...
@@ -41,4 +41,9 @@ public interface WorkHandoverService {
* 交接人
* 交接人
*/
*/
List
<
User
>
handover
(
List
<
Integer
>
userIds
);
List
<
User
>
handover
(
List
<
Integer
>
userIds
);
/**
* 终止工作交接
*/
void
terminateWorkHandover
(
Integer
billId
);
}
}
dev-train/src/main/java/com/tykj/dev/device/train/service/impl/WorkHandoverServiceImpl.java
浏览文件 @
bd08790d
...
@@ -187,6 +187,22 @@ public class WorkHandoverServiceImpl implements WorkHandoverService {
...
@@ -187,6 +187,22 @@ public class WorkHandoverServiceImpl implements WorkHandoverService {
return
userService
.
findAllUserIdInUser
(
userIds
);
return
userService
.
findAllUserIdInUser
(
userIds
);
}
}
@Override
public
void
terminateWorkHandover
(
Integer
billId
)
{
Optional
<
WorkHandover
>
byId
=
workHandoverDao
.
findById
(
billId
);
if
(
byId
.
isPresent
()){
WorkHandover
workHandover
=
byId
.
get
();
workHandover
.
setStatus
(
3
);
workHandoverDao
.
save
(
workHandover
);
TaskBto
taskBto
=
trainTaskService
.
selectFatherIsNullAndBillidAndBillType
(
workHandover
.
getWorkHandoverId
(),
BusinessEnum
.
WORK_HANDOVER
.
id
);
taskService
.
moveToArchive
(
taskBto
);
}
else
{
throw
new
ApiException
(
"[工作交接] 终止工作交接任务"
);
}
}
private
void
addMessage
(
MessageBto
messageBto
){
private
void
addMessage
(
MessageBto
messageBto
){
messageService
.
add
(
messageBto
);
messageService
.
add
(
messageBto
);
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论