Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
44470ddb
提交
44470ddb
authored
3月 14, 2021
作者:
133
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[退役] 代码提交
上级
184b1d0c
隐藏空白字符变更
内嵌
并排
正在显示
12 个修改的文件
包含
95 行增加
和
29 行删除
+95
-29
StatusEnum.java
...misc/src/main/java/com/tykj/dev/misc/base/StatusEnum.java
+1
-1
RepelQueryController.java
.../dev/device/sendback/controller/RepelQueryController.java
+3
-3
RepelTaskStatistical.java
...v/device/sendback/entity/domain/RepelTaskStatistical.java
+1
-1
DeviceChooseRepel.java
...tykj/dev/device/sendback/entity/vo/DeviceChooseRepel.java
+5
-0
RepelQueryService.java
...m/tykj/dev/device/sendback/service/RepelQueryService.java
+1
-1
RepelBusinessServiceImpl.java
...evice/sendback/service/impl/RepelBusinessServiceImpl.java
+16
-11
RepelQueryServiceImpl.java
...v/device/sendback/service/impl/RepelQueryServiceImpl.java
+29
-6
TaskDao.java
...ain/java/com/tykj/dev/device/task/repository/TaskDao.java
+1
-0
TaskService.java
...in/java/com/tykj/dev/device/task/service/TaskService.java
+11
-0
TaskServiceImpl.java
...om/tykj/dev/device/task/service/impl/TaskServiceImpl.java
+19
-0
bill.html
dev-union/src/main/resources/bill.html
+4
-3
bill1.html
dev-union/src/main/resources/bill1.html
+4
-3
没有找到文件。
dev-misc/src/main/java/com/tykj/dev/misc/base/StatusEnum.java
浏览文件 @
44470ddb
...
...
@@ -80,7 +80,7 @@ public enum StatusEnum {
SEND_BACK_1207
(
1207
,
"清退装备等待审核确认"
),
SEND_BACK_1208
(
1208
,
"清退装备等待出库"
),
SEND_BACK_1209
(
1209
,
"清退装备等待入库"
),
SEND_BACK_1210
(
1210
,
"省
清退送往中办
等待回执单"
),
SEND_BACK_1210
(
1210
,
"省
退役送往省外
等待回执单"
),
SEND_BACK_1211
(
1211
,
"市发清退任务待省审核"
),
SEND_BACK_1212
(
1212
,
"清退统计任务待办结"
),
SEND_BACK_1213
(
1213
,
"省直属清退任务待上传单据"
),
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/controller/RepelQueryController.java
浏览文件 @
44470ddb
...
...
@@ -63,10 +63,10 @@ public class RepelQueryController {
return
ResponseEntity
.
ok
(
repelQueryService
.
findDeviceRepel
(
taskId
));
}
@PostMapping
(
value
=
"/deviceChooseRepel/{unitId}"
)
@PostMapping
(
value
=
"/deviceChooseRepel/{unitId}
/{taskId}
"
)
@ApiOperation
(
value
=
"代办任务通知页面详情"
,
notes
=
"代办任务通知页面详情"
)
public
ResponseEntity
findDeviceRepel
(
@RequestBody
List
<
Integer
>
fielding
,
@PathVariable
Integer
unit
Id
){
return
ResponseEntity
.
ok
(
repelQueryService
.
findDeviceChooseRepel
(
fielding
,
unitId
));
public
ResponseEntity
findDeviceRepel
(
@RequestBody
List
<
Integer
>
fielding
,
@PathVariable
Integer
unitId
,
@PathVariable
Integer
task
Id
){
return
ResponseEntity
.
ok
(
repelQueryService
.
findDeviceChooseRepel
(
fielding
,
unitId
,
taskId
));
}
@PostMapping
(
value
=
"/deviceChooseRepel1/{unitId}"
)
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/entity/domain/RepelTaskStatistical.java
浏览文件 @
44470ddb
...
...
@@ -52,7 +52,7 @@ public class RepelTaskStatistical extends BaseEntity {
private
Integer
taskId
;
/**
* 任务状态
1.正常提交 2.延期 3.等待审核
* 任务状态
0.等待处理 1.清退完成 2.延期 3.等待审核 4.待补全单据 5.待下级单位清退装备
*/
@ApiModelProperty
(
value
=
"任务状态 1.正常提交 2.延期 3.等待审核 4.等待上传单据"
)
private
Integer
taskStatus
;
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/entity/vo/DeviceChooseRepel.java
浏览文件 @
44470ddb
...
...
@@ -24,4 +24,9 @@ public class DeviceChooseRepel {
private
List
<
DeviceLibrary
>
deviceLibraries
;
private
List
<
DeviceLibrary
>
deviceLibrariesAbnormal
;
/**
* 是否可以提交 1。可以 0。不可以 用于判读市下级任务是否都完成了
*/
private
Integer
isNotSubmit
;
}
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/RepelQueryService.java
浏览文件 @
44470ddb
...
...
@@ -33,7 +33,7 @@ public interface RepelQueryService {
/**
* 根据列装id,以及当前用户
*/
DeviceChooseRepel
findDeviceChooseRepel
(
List
<
Integer
>
fielding
,
Integer
unitId
);
DeviceChooseRepel
findDeviceChooseRepel
(
List
<
Integer
>
fielding
,
Integer
unitId
,
Integer
taskId
);
/**
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/impl/RepelBusinessServiceImpl.java
浏览文件 @
44470ddb
...
...
@@ -228,7 +228,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
DeviceRepelDetail
deviceRepelDetail
=
new
DeviceRepelDetail
();
deviceRepelDetail
.
setRepelId
(
deviceRepel1
.
getId
());
deviceRepelDetail
.
setRepelStatus
(
1
);
TaskBto
taskBto
=
cityTotalTask
(
units
.
getUnitId
(),
deviceRepel1
.
getId
(),
deviceRepel
.
getTitle
());
TaskBto
taskBto
=
cityTotalTask
(
units
.
getUnitId
(),
deviceRepel1
.
getId
(),
deviceRepel
.
getTitle
()
,
taskId
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
user
.
getName
()+
"转发清退任务["
+
deviceRepel1
.
getTitle
()+
"]"
,
gainThisUser
(
userId
,
units
.
getUnitId
())));
// repelTaskStatisticalService.saveRepelTaskStatistical(new RepelTaskStatistical(deviceRepel1.getId(),null,taskBto.getId(),null,area.getName()));
...
...
@@ -264,9 +264,15 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
if
(
list
==
null
||
list
.
size
()==
0
){
taskService
.
moveToSpecial
(
taskBto
,
StatusEnum
.
SEND_BACK_1212
,
userId
);
}
repelTaskStatisticalService
.
saveAllRepelTaskStatistical
(
list
);
TaskBto
currentTask
=
taskService
.
get
(
taskId
);
taskService
.
moveToSpecial
(
currentTask
,
StatusEnum
.
SEND_BACK_1206
);
repelTaskStatisticalService
.
saveAllRepelTaskStatistical
(
list
);
TaskBto
currentTask
=
taskService
.
get
(
taskId
);
log
.
info
(
"------{}"
,
currentTask
);
DeviceRepelDetail
deviceRepelDetail1
=
deviceRepelDetailService
.
findDeviceRepelDetail
(
currentTask
.
getBillId
());
RepelTaskStatistical
repelTaskStatistical
=
repelTaskStatisticalService
.
findRepelTaskStatistical
(
currentTask
.
getId
(),
deviceRepelDetail1
.
getRepelId
());
repelTaskStatistical
.
setTaskStatus
(
5
);
repelTaskStatisticalService
.
saveRepelTaskStatistical
(
repelTaskStatistical
);
taskService
.
moveToSpecial
(
currentTask
,
StatusEnum
.
SEND_BACK_1206
);
// isEnd(taskBto,deviceRepel1.getId());
}
...
...
@@ -713,8 +719,8 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
deviceRepelDetail
.
setReceiveUseraId
(
storageDeviceRepel
.
getUserA
());
}
if
(
storageDeviceRepel
.
getUser
B
Name
()!=
null
)
{
deviceRepelDetail
.
setReceiveUserA
(
storageDeviceRepel
.
getUser
B
Name
());
if
(
storageDeviceRepel
.
getUser
A
Name
()!=
null
)
{
deviceRepelDetail
.
setReceiveUserA
(
storageDeviceRepel
.
getUser
A
Name
());
}
taskService
.
moveToEnd
(
taskBto
);
deviceRepelDetail
.
setRepelStatus
(
2
);
...
...
@@ -808,17 +814,16 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
}
/**
* 市的清退
总
任务 17
* 市的清退
统计任务
任务 17
* @param unitId
* @param repelDetailId
* @param title
* @return
*/
private
TaskBto
cityTotalTask
(
Integer
unitId
,
Integer
repelDetailId
,
String
title
){
//省清退任务待市提交
private
TaskBto
cityTotalTask
(
Integer
unitId
,
Integer
repelDetailId
,
String
title
,
Integer
parentId
){
List
<
Integer
>
list
=
new
ArrayList
<>();
list
.
add
(-
1
);
return
taskService
.
start
(
new
TaskBto
(
StatusEnum
.
SEND_BACK_1204
.
id
,
title
,
null
,
"."
,
repelDetailId
,
BusinessEnum
.
SEND_BACK_STATISTICAL
.
id
,
unitId
,
0
,
"
"
,
list
));
return
taskService
.
start
(
new
TaskBto
(
StatusEnum
.
SEND_BACK_1204
.
id
,
title
,
parentId
,
"."
,
repelDetailId
,
BusinessEnum
.
SEND_BACK_STATISTICAL
.
id
,
unitId
,
0
,
"shi
"
,
list
));
}
// private String listIdsToString(List<Integer> idList){
// StringBuffer stringBuffer=new StringBuffer();
...
...
@@ -907,7 +912,7 @@ public class RepelBusinessServiceImpl implements RepelBusinessService {
private
TaskBto
sendOutSuperior
(
Integer
unitId
,
Integer
repelDetailId
,
Integer
parentTaskId
){
List
<
Integer
>
list
=
new
ArrayList
<>();
list
.
add
(
0
);
return
taskService
.
start
(
new
TaskBto
(
StatusEnum
.
SEND_BACK_1210
.
id
,
"省
本级装备清退"
,
parentTaskId
,
"."
,
repelDetailId
,
BusinessEnum
.
SEND_BACK
.
id
,
unitId
,
0
,
"
"
,
list
));
return
taskService
.
start
(
new
TaskBto
(
StatusEnum
.
SEND_BACK_1210
.
id
,
"省
退役国家装备任务"
,
parentTaskId
,
"."
,
repelDetailId
,
BusinessEnum
.
SEND_BACK
.
id
,
unitId
,
0
,
"country
"
,
list
));
}
private
List
<
DeviceLibrary
>
findInvoleDevice
(
String
involeDevice
){
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/impl/RepelQueryServiceImpl.java
浏览文件 @
44470ddb
...
...
@@ -17,6 +17,7 @@ import com.tykj.dev.device.user.subject.entity.Units;
import
com.tykj.dev.device.user.subject.service.UnitsService
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.DeviceLifeStatus
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -78,7 +79,7 @@ public class RepelQueryServiceImpl implements RepelQueryService {
}
@Override
public
DeviceChooseRepel
findDeviceChooseRepel
(
List
<
Integer
>
fielding
,
Integer
unitId
)
{
public
DeviceChooseRepel
findDeviceChooseRepel
(
List
<
Integer
>
fielding
,
Integer
unitId
,
Integer
taskId
)
{
List
<
DeviceLibrary
>
deviceLibraries
=
new
ArrayList
<>();
List
<
DeviceLibrary
>
deviceLibrariesAbnormal
=
new
ArrayList
<>();
Units
units
=
unitsService
.
findById
(
unitId
);
...
...
@@ -101,7 +102,22 @@ public class RepelQueryServiceImpl implements RepelQueryService {
}
}
);
return
new
DeviceChooseRepel
(
deviceLibraries
,
deviceLibrariesAbnormal
);
int
isNotSub
=
1
;
if
(
units
.
getLevel
()==
2
)
{
TaskBto
taskBto
=
taskService
.
findFatherIdAndCustomInfo
(
taskId
);
// DeviceRepelDetail deviceRepelDetail= repelDetailService.findDeviceRepelDetail(taskBto.getBillId());
// boolean flag= repelTaskStatisticalService.findAllRepelTaskStatistical(taskBto.getParentTaskId(),deviceRepelDetail.getRepelId()).stream().allMatch(e->e.getTaskStatus()==1);
// if (flag){
// TaskBto parentTask= taskService.get(taskBto.getParentTaskId());
// if (parentTask.getBillStatus()!= StatusEnum.END.id) {
// taskService.moveToSpecial(parentTask, StatusEnum.SEND_BACK_1212, 0);
// }
// }
if
(!
taskBto
.
getBillStatus
().
equals
(
StatusEnum
.
END
.
id
))
{
isNotSub
=
0
;
}
}
return
new
DeviceChooseRepel
(
deviceLibraries
,
deviceLibrariesAbnormal
,
isNotSub
);
}
@Override
...
...
@@ -243,9 +259,16 @@ public class RepelQueryServiceImpl implements RepelQueryService {
@Override
public
List
<
TaskBto
>
findOutsideTheProvince
()
{
List
<
Integer
>
unitIds
=
unitsService
.
findSuperiorUnitsList
().
stream
().
map
(
Units:
:
getUnitId
).
collect
(
Collectors
.
toList
());
List
<
DeviceRepelDetail
>
list
=
repelDetailService
.
findIdsReceiptUnits
(
unitIds
);
return
taskService
.
findBillIdAndBillType
(
list
.
stream
().
map
(
DeviceRepelDetail:
:
getId
).
collect
(
Collectors
.
toList
()),
BusinessEnum
.
SEND_BACK
.
id
);
List
<
TaskBto
>
taskBtoList
=
new
ArrayList
<>();
taskService
.
findBillType
(
BusinessEnum
.
SEND_BACK
.
id
).
forEach
(
taskBto
->
{
if
(
taskBto
.
getCustomInfo
().
equals
(
"country"
)){
taskBtoList
.
add
(
taskBto
);
}
}
);
return
taskBtoList
;
}
@Override
...
...
@@ -271,7 +294,7 @@ public class RepelQueryServiceImpl implements RepelQueryService {
}
}
);
return
new
DeviceChooseRepel
(
deviceLibraries
,
deviceLibrariesAbnormal
);
return
new
DeviceChooseRepel
(
deviceLibraries
,
deviceLibrariesAbnormal
,
1
);
}
private
DevRepelVo
devRepelVo
(
DeviceLibrary
deviceLibrary
){
...
...
dev-task/src/main/java/com/tykj/dev/device/task/repository/TaskDao.java
浏览文件 @
44470ddb
...
...
@@ -68,4 +68,5 @@ public interface TaskDao extends JpaRepository<Task, Integer>, JpaSpecificationE
List
<
Task
>
findAllByBusinessType
(
Integer
businessType
);
List
<
Task
>
findAllByBillIdInAndBusinessType
(
List
<
Integer
>
ids
,
Integer
type
);
}
dev-task/src/main/java/com/tykj/dev/device/task/service/TaskService.java
浏览文件 @
44470ddb
...
...
@@ -170,4 +170,15 @@ public interface TaskService {
* 根据业务id 以及 业务类型进行查询
*/
List
<
TaskBto
>
findBillIdAndBillType
(
List
<
Integer
>
billIds
,
Integer
billType
);
/**
* 根据父id查询customInfo为shi的task
*/
TaskBto
findFatherIdAndCustomInfo
(
Integer
taskId
);
/**
* 根据billType 查询task集合
*/
List
<
TaskBto
>
findBillType
(
Integer
billType
);
}
dev-task/src/main/java/com/tykj/dev/device/task/service/impl/TaskServiceImpl.java
浏览文件 @
44470ddb
...
...
@@ -20,6 +20,7 @@ import com.tykj.dev.device.user.cache.UserCache;
import
com.tykj.dev.device.user.subject.entity.User
;
import
com.tykj.dev.device.user.subject.service.UserPublicService
;
import
com.tykj.dev.device.user.util.UserUtils
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.exception.ApiException
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
...
...
@@ -27,6 +28,7 @@ import com.tykj.dev.misc.utils.ResultUtil;
import
com.tykj.dev.socket.MyWebSocket
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.jpa.domain.Specification
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
...
...
@@ -620,6 +622,23 @@ public class TaskServiceImpl implements TaskService {
return
taskDao
.
findAllByBillIdInAndBusinessType
(
billIds
,
billType
).
stream
().
map
(
Task:
:
parse2Bto
).
collect
(
Collectors
.
toList
());
}
@Override
public
TaskBto
findFatherIdAndCustomInfo
(
Integer
taskId
)
{
List
<
TaskBto
>
taskBtos
=
taskDao
.
findAllByParentTaskId
(
taskId
).
stream
().
filter
(
task
->
task
.
getCustomInfo
().
equals
(
"shi"
)).
map
(
Task:
:
parse2Bto
).
collect
(
Collectors
.
toList
());
for
(
TaskBto
taskBto:
taskBtos
){
if
(
taskBto
.
getCustomInfo
().
equals
(
"shi"
)){
return
taskBto
;
}
}
throw
new
ApiException
(
ResponseEntity
.
status
(
500
).
body
(
"[清退] id:"
+
taskId
+
"没有找到子类CustomInfo为shi的"
));
}
@Override
public
List
<
TaskBto
>
findBillType
(
Integer
billType
)
{
return
taskDao
.
findAllByBusinessType
(
billType
).
stream
().
map
(
Task:
:
parse2Bto
).
collect
(
Collectors
.
toList
());
}
/**
* @param taskSelectVo 查询vo
* 查询跟踪和待办列表
...
...
dev-union/src/main/resources/bill.html
浏览文件 @
44470ddb
...
...
@@ -312,7 +312,7 @@
<div
class=
"line2 tableList"
>
<table
class=
"altrowstable"
id=
"alternatecolor"
>
<tr>
<th>
序号
</th><th>
型号
</th><th>
形态
</th><th>
密级
</th><th>
应用领域
</th><th>
数量
</th><th
style=
"width: 420px;"
>
装备序列号
</th>
<th>
序号
</th><th>
型号
</th><th>
形态
</th><th>
密级
</th><th>
应用领域
</th><th>
数量
</th><th
style=
"width: 420px;"
>
装备序列号
</th>
<th>
备注
</th>
</tr>
<
#
list
documentDevices
as
dev
>
<tr>
...
...
@@ -321,13 +321,14 @@
${dev.code}
</
#
if>
</td>
<td>
${dev.model
}
</td><td>
${dev.category}
</td><td>
${dev.securityClassification}
</td><td>
${dev.applicationField
}
</td>
<td>
${dev.model
!}
</td><td>
${dev.category!}
</td><td>
${dev.securityClassification!}
</td><td>
${dev.applicationField!
}
</td>
<td>
<
#
if
dev
.
count
!=
0
>
${dev.count}
</
#
if>
</td>
<td>
${dev.deviceSerialNumber}
</td>
<td>
${dev.deviceSerialNumber!}
</td>
<td>
${dev.remark!}
</td>
</tr>
</
#
list>
</table>
...
...
dev-union/src/main/resources/bill1.html
浏览文件 @
44470ddb
...
...
@@ -310,7 +310,7 @@
<div
class=
"line2 tableList"
>
<table
class=
"altrowstable"
id=
"alternatecolor"
>
<tr>
<th>
序号
</th><th>
型号
</th><th>
形态
</th><th>
密级
</th><th>
应用领域
</th><th>
数量
</th><th
style=
"width: 420px;"
>
装备序列号
</th>
<th>
序号
</th><th>
型号
</th><th>
形态
</th><th>
密级
</th><th>
应用领域
</th><th>
数量
</th><th
style=
"width: 420px;"
>
装备序列号
</th>
<th>
备注
</th>
</tr>
<
#
list
documentDevices
as
dev
>
<tr>
...
...
@@ -319,12 +319,13 @@
${dev.code}
</
#
if>
</td>
<td>
${dev.model
}
</td><td>
${dev.category}
</td><td>
${dev.securityClassification}
</td><td>
${dev.applicationField
}
</td>
<td>
${dev.model
!}
</td><td>
${dev.category!}
</td><td>
${dev.securityClassification!}
</td><td>
${dev.applicationField!
}
</td>
<td>
<
#
if
dev
.
count
!=
0
>
${dev.count}
</
#
if>
</td><td>
${dev.deviceSerialNumber}
</td>
</td><td>
${dev.deviceSerialNumber!}
</td>
<td>
${dev.remark!}
</td>
</tr>
</
#
list>
</table>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论