Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
79e12293
提交
79e12293
authored
3月 22, 2021
作者:
邓砥奕
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
更新
上级
be982952
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
33 个修改的文件
包含
289 行增加
和
107 行删除
+289
-107
AllotBillController.java
...tykj/dev/device/allot/controller/AllotBillController.java
+18
-5
AllotBillSelectController.java
...ev/device/allot/controller/AllotBillSelectController.java
+2
-0
BackController.java
.../com/tykj/dev/device/allot/controller/BackController.java
+15
-3
AllotBackBillServiceImpl.java
...v/device/allot/service/impl/AllotBackBillServiceImpl.java
+12
-2
AllotBillServiceImpl.java
...j/dev/device/allot/service/impl/AllotBillServiceImpl.java
+12
-4
AllotBackBill.java
...om/tykj/dev/device/allot/subject/domin/AllotBackBill.java
+6
-0
AllotBill.java
...va/com/tykj/dev/device/allot/subject/domin/AllotBill.java
+6
-0
AllotBackReceiveVo.java
.../tykj/dev/device/allot/subject/vo/AllotBackReceiveVo.java
+5
-0
AllotReceiveVo.java
.../com/tykj/dev/device/allot/subject/vo/AllotReceiveVo.java
+5
-0
FileUploadVo.java
...va/com/tykj/dev/device/allot/subject/vo/FileUploadVo.java
+5
-0
DeviceCheckController.java
...device/confirmcheck/controller/DeviceCheckController.java
+3
-5
CheckBillSelectVo.java
.../dev/device/confirmcheck/entity/vo/CheckBillSelectVo.java
+14
-0
ConfirmCheckService.java
.../dev/device/confirmcheck/service/ConfirmCheckService.java
+2
-5
ConfirmCheckServiceImpl.java
...ce/confirmcheck/service/impl/ConfirmCheckServiceImpl.java
+7
-11
FinalCheckController.java
...ev/device/finalcheck/controller/FinalCheckController.java
+8
-17
FinalCheckService.java
...tykj/dev/device/finalcheck/service/FinalCheckService.java
+2
-7
FinalCheckServiceImpl.java
...device/finalcheck/service/impl/FinalCheckServiceImpl.java
+9
-9
PackingLibraryServiceImpl.java
...evice/packing/service/impl/PackingLibraryServiceImpl.java
+1
-0
RepairBillSelectController.java
.../device/repair/controller/RepairBillSelectController.java
+7
-1
RepairController.java
...m/tykj/dev/device/repair/controller/RepairController.java
+0
-0
RepairBackBill.java
.../tykj/dev/device/repair/subject/domin/RepairBackBill.java
+6
-0
RepairSendBill.java
.../tykj/dev/device/repair/subject/domin/RepairSendBill.java
+6
-0
FileUploadVo.java
...a/com/tykj/dev/device/repair/subject/vo/FileUploadVo.java
+4
-0
FileVo.java
...in/java/com/tykj/dev/device/repair/subject/vo/FileVo.java
+7
-1
RepairReceiveVo.java
...om/tykj/dev/device/repair/subject/vo/RepairReceiveVo.java
+5
-0
SelfCheckController.java
.../dev/device/selfcheck/controller/SelfCheckController.java
+21
-0
StatisticalController.java
...ykj/dev/statistical/controller/StatisticalController.java
+19
-1
StorageBillController.java
.../dev/device/storage/controller/StorageBillController.java
+14
-17
StorageBill.java
...om/tykj/dev/device/storage/subject/domin/StorageBill.java
+2
-2
StorageBillDetail.java
...tykj/dev/device/storage/subject/vo/StorageBillDetail.java
+32
-0
StorageBillSaveVo.java
...tykj/dev/device/storage/subject/vo/StorageBillSaveVo.java
+2
-2
TaskSelectController.java
...ev/device/taskselect/controller/TaskSelectController.java
+2
-0
LogAspect.java
dev-union/src/main/java/com/tykj/dev/union/LogAspect.java
+30
-15
没有找到文件。
dev-allot/src/main/java/com/tykj/dev/device/allot/controller/AllotBillController.java
浏览文件 @
79e12293
...
...
@@ -336,9 +336,16 @@ public class AllotBillController {
TaskBto
taskBto
=
taskService
.
get
(
allotReceiveVo
.
getTaskId
());
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
ALLOTING
);
AllotBill
allotBillEntity
=
allotBillService
.
getOne
(
taskBto
.
getBillId
());
boolean
sendbIsExist
=
allotBillEntity
.
getSendUserbId
()!=
null
;
List
<
FileVo
>
fileVoList
=
new
ArrayList
<>();
if
(
allotReceiveVo
.
getBillFileName
()!=
null
&&
allotReceiveVo
.
getBillFileUrl
()!=
null
)
{
fileVoList
.
add
(
new
FileVo
(
"配发单"
,
allotReceiveVo
.
getBillFileName
(),
allotReceiveVo
.
getBillFileUrl
()));
// if (allotReceiveVo.getBillFileName()!=null&&allotReceiveVo.getBillFileUrl()!=null) {
// fileVoList.add(new FileVo("配发单", allotReceiveVo.getBillFileName(), allotReceiveVo.getBillFileUrl()));
// }
if
(
allotReceiveVo
.
getReceiveFiles
()!=
null
&&
allotReceiveVo
.
getReceiveFiles
().
size
()>
0
){
allotReceiveVo
.
getReceiveFiles
().
forEach
(
fileRet
->
{
fileVoList
.
add
(
new
FileVo
(
"配发单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
allotBillEntity
.
setReceiveFiles
(
FilesUtil
.
stringFileToList
(
allotReceiveVo
.
getReceiveFiles
()));
}
// fileVoList.add(new FileVo("入库确认单", allotReceiveVo.getReceiveFileName(), allotReceiveVo.getReceiveFileUrl()));
//更新账单状态
...
...
@@ -417,7 +424,7 @@ public class AllotBillController {
MessageBto
messageBto
=
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"被选为经办人"
,
idList1
,
1
);
messageService
.
add
(
messageBto
);
}
if
(
allotReceiveVo
.
getSendUserbId
()!=
null
)
{
if
(
allotReceiveVo
.
getSendUserbId
()!=
null
&&
sendbIsExist
)
{
List
<
Integer
>
idList1
=
new
ArrayList
<>();
idList1
.
add
(
allotReceiveVo
.
getSendUserbId
());
MessageBto
messageBto
=
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"被选为签发人"
,
idList1
,
1
);
...
...
@@ -613,9 +620,15 @@ public class AllotBillController {
allotBill
.
setSendUserbId
(
fileUploadVo
.
getSendUserbId
());
allotBill
.
setAgent
(
userPublicService
.
getOne
(
fileUploadVo
.
getSendUserbId
()).
getName
());
}
allotBillService
.
update
(
allotBill
);
List
<
FileVo
>
fileVoList
=
new
ArrayList
<>();
fileVoList
.
add
(
new
FileVo
(
"配发单"
,
allotBill
.
getBillFileName
(),
allotBill
.
getBillFileUrl
()));
if
(
fileUploadVo
.
getReceiveFiles
()!=
null
&&
fileUploadVo
.
getReceiveFiles
().
size
()>
0
){
fileUploadVo
.
getReceiveFiles
().
forEach
(
fileRet
->
{
fileVoList
.
add
(
new
FileVo
(
"配发单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
allotBill
.
setReceiveFiles
(
FilesUtil
.
stringFileToList
(
fileUploadVo
.
getReceiveFiles
()));
}
// fileVoList.add(new FileVo("配发单", allotBill.getBillFileName(), allotBill.getBillFileUrl()));
allotBillService
.
update
(
allotBill
);
//添加装备日志
List
<
Integer
>
deviceIds
=
StringSplitUtil
.
split
(
allotBill
.
getAllotCheckDetail
());
deviceIds
.
forEach
(
integer
->
{
...
...
dev-allot/src/main/java/com/tykj/dev/device/allot/controller/AllotBillSelectController.java
浏览文件 @
79e12293
...
...
@@ -80,6 +80,7 @@ public class AllotBillSelectController {
allotBillEntity
.
setReceiveUserB
(
userService
.
getOne
(
allotBillEntity
.
getReceiveUserbId
()).
getName
());
}
allotBillEntity
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getSendFiles
()));
allotBillEntity
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReceiveFiles
()));
allotBillEntity
.
setReplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReplyFiles
()));
allotBillEntity
.
setApplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getApplyFiles
()));
if
(
allotBillEntity
.
getScriptJson
()!=
null
){
...
...
@@ -113,6 +114,7 @@ public class AllotBillSelectController {
allotBillEntity
.
setReceiveUserB
(
userService
.
getOne
(
allotBillEntity
.
getReceiveUserbId
()).
getName
());
}
allotBillEntity
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getSendFiles
()));
allotBillEntity
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReceiveFiles
()));
allotBillEntity
.
setReplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReplyFiles
()));
allotBillEntity
.
setApplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getApplyFiles
()));
if
(
allotBillEntity
.
getScriptJson
()!=
null
){
...
...
dev-allot/src/main/java/com/tykj/dev/device/allot/controller/BackController.java
浏览文件 @
79e12293
...
...
@@ -167,7 +167,13 @@ public class BackController {
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
ALLOT_BACKING
);
AllotBackBill
allotBackBill
=
allotBackBillService
.
getOne
(
taskBto
.
getBillId
());
List
<
FileVo
>
fileVoList
=
new
ArrayList
<>();
fileVoList
.
add
(
new
FileVo
(
"退回单"
,
allotBackReceiveVo
.
getBillFileName
(),
allotBackReceiveVo
.
getBillFileUrl
()));
if
(
allotBackReceiveVo
.
getReceiveFiles
()!=
null
&&
allotBackReceiveVo
.
getReceiveFiles
().
size
()>
0
){
allotBackReceiveVo
.
getReceiveFiles
().
forEach
(
fileRet
->
{
fileVoList
.
add
(
new
FileVo
(
"退回单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
allotBackBill
.
setReceiveFiles
(
FilesUtil
.
stringFileToList
(
allotBackReceiveVo
.
getReceiveFiles
()));
}
// fileVoList.add(new FileVo("退回单", allotBackReceiveVo.getBillFileName(), allotBackReceiveVo.getBillFileUrl()));
// fileVoList.add(new FileVo("入库确认单", allotReceiveVo.getReceiveFileName(), allotReceiveVo.getReceiveFileUrl()));
//更新账单状态
allotBackBill
.
setBackStatus
(
3
);
...
...
@@ -268,9 +274,15 @@ public class BackController {
allotBackBill
.
setSendUserbId
(
fileUploadVo
.
getSendUserbId
());
allotBackBill
.
setAgent
(
userPublicService
.
getOne
(
fileUploadVo
.
getSendUserbId
()).
getName
());
}
allotBackBillService
.
update
(
allotBackBill
);
List
<
FileVo
>
fileVoList
=
new
ArrayList
<>();
fileVoList
.
add
(
new
FileVo
(
"退回单"
,
allotBackBill
.
getBillFileName
(),
allotBackBill
.
getBillFileUrl
()));
if
(
fileUploadVo
.
getReceiveFiles
()!=
null
&&
fileUploadVo
.
getReceiveFiles
().
size
()>
0
){
fileUploadVo
.
getReceiveFiles
().
forEach
(
fileRet
->
{
fileVoList
.
add
(
new
FileVo
(
"退回单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
allotBackBill
.
setReceiveFiles
(
FilesUtil
.
stringFileToList
(
fileUploadVo
.
getReceiveFiles
()));
}
allotBackBillService
.
update
(
allotBackBill
);
// fileVoList.add(new FileVo("退回单", allotBackBill.getBillFileName(), allotBackBill.getBillFileUrl()));
//添加装备日志
List
<
Integer
>
deviceIds
=
StringSplitUtil
.
split
(
allotBackBill
.
getBackCheckDetail
());
deviceIds
.
forEach
(
integer
->
{
...
...
dev-allot/src/main/java/com/tykj/dev/device/allot/service/impl/AllotBackBillServiceImpl.java
浏览文件 @
79e12293
...
...
@@ -99,8 +99,18 @@ public class AllotBackBillServiceImpl implements AllotBackBillService {
public
Page
<
AllotBackBill
>
getPage
(
AllotBillSelectVo
allotBillSelectVo
,
Pageable
pageable
)
{
Page
<
AllotBackBill
>
page
=
allotBackBillDao
.
findAll
(
getSelectSpecification
(
allotBillSelectVo
),
pageable
);
for
(
AllotBackBill
a
:
page
.
getContent
())
{
a
.
setSenderUserA
(
userPublicService
.
getOne
(
a
.
getSendUseraId
()).
getName
());
a
.
setReceiveUserA
(
userPublicService
.
getOne
(
a
.
getReceiveUseraId
()).
getName
());
if
(
a
.
getSendUseraId
()!=
null
)
{
a
.
setSenderUserA
(
userPublicService
.
getOne
(
a
.
getSendUseraId
()).
getName
());
}
if
(
a
.
getSendUserbId
()!=
null
)
{
a
.
setSenderUserB
(
userPublicService
.
getOne
(
a
.
getSendUserbId
()).
getName
());
}
if
(
a
.
getReceiveUseraId
()!=
null
)
{
a
.
setReceiveUserA
(
userPublicService
.
getOne
(
a
.
getReceiveUseraId
()).
getName
());
}
if
(
a
.
getReceiveUserbId
()!=
null
)
{
a
.
setReceiveUserB
(
userPublicService
.
getOne
(
a
.
getReceiveUserbId
()).
getName
());
}
}
return
page
;
}
...
...
dev-allot/src/main/java/com/tykj/dev/device/allot/service/impl/AllotBillServiceImpl.java
浏览文件 @
79e12293
...
...
@@ -86,10 +86,18 @@ public class AllotBillServiceImpl implements AllotBillService {
public
Page
<
AllotBill
>
getPage
(
AllotBillSelectVo
allotBillSelectVo
,
Pageable
pageable
)
{
Page
<
AllotBill
>
page
=
allotBillDao
.
findAll
(
getSelectSpecification
(
allotBillSelectVo
),
pageable
);
for
(
AllotBill
a
:
page
.
getContent
())
{
a
.
setSenderUserA
(
userPublicService
.
getOne
(
a
.
getSendUseraId
()).
getName
());
a
.
setSenderUserB
(
userPublicService
.
getOne
(
a
.
getSendUserbId
()).
getName
());
a
.
setReceiveUserA
(
userPublicService
.
getOne
(
a
.
getReceiveUseraId
()).
getName
());
a
.
setReceiveUserB
(
userPublicService
.
getOne
(
a
.
getReceiveUserbId
()).
getName
());
if
(
a
.
getSendUseraId
()!=
null
)
{
a
.
setSenderUserA
(
userPublicService
.
getOne
(
a
.
getSendUseraId
()).
getName
());
}
if
(
a
.
getSendUserbId
()!=
null
)
{
a
.
setSenderUserB
(
userPublicService
.
getOne
(
a
.
getSendUserbId
()).
getName
());
}
if
(
a
.
getReceiveUseraId
()!=
null
)
{
a
.
setReceiveUserA
(
userPublicService
.
getOne
(
a
.
getReceiveUseraId
()).
getName
());
}
if
(
a
.
getReceiveUserbId
()!=
null
)
{
a
.
setReceiveUserB
(
userPublicService
.
getOne
(
a
.
getReceiveUserbId
()).
getName
());
}
}
return
page
;
}
...
...
dev-allot/src/main/java/com/tykj/dev/device/allot/subject/domin/AllotBackBill.java
浏览文件 @
79e12293
...
...
@@ -176,6 +176,9 @@ public class AllotBackBill {
@Column
(
name
=
"send_files"
,
columnDefinition
=
"TEXT"
)
private
String
sendFiles
;
@Column
(
name
=
"receive_files"
,
columnDefinition
=
"TEXT"
)
private
String
receiveFiles
;
@Column
(
name
=
"apply_files"
,
columnDefinition
=
"TEXT"
)
private
String
applyFiles
;
...
...
@@ -193,4 +196,7 @@ public class AllotBackBill {
@Transient
private
List
<
FileRet
>
applyFileList
=
new
ArrayList
<>();
@Transient
private
List
<
FileRet
>
receiveFileList
=
new
ArrayList
<>();
}
dev-allot/src/main/java/com/tykj/dev/device/allot/subject/domin/AllotBill.java
浏览文件 @
79e12293
...
...
@@ -253,6 +253,9 @@ public class AllotBill {
@Column
(
name
=
"send_files"
,
columnDefinition
=
"TEXT"
)
private
String
sendFiles
;
@Column
(
name
=
"receive_files"
,
columnDefinition
=
"TEXT"
)
private
String
receiveFiles
;
@Column
(
name
=
"script_json"
,
columnDefinition
=
"TEXT"
)
private
String
scriptJson
;
...
...
@@ -268,4 +271,7 @@ public class AllotBill {
@Transient
private
List
<
FileRet
>
sendFileList
=
new
ArrayList
<>();
@Transient
private
List
<
FileRet
>
receiveFileList
=
new
ArrayList
<>();
}
dev-allot/src/main/java/com/tykj/dev/device/allot/subject/vo/AllotBackReceiveVo.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
allot
.
subject
.
vo
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.validation.constraints.Min
;
import
javax.validation.constraints.NotNull
;
import
java.util.List
;
/**
* @author dengdiyi
...
...
@@ -58,4 +60,7 @@ public class AllotBackReceiveVo {
@NotNull
(
message
=
"status不能为空"
)
@ApiModelProperty
(
value
=
"是否缺失单据(0:否,1:是)"
)
private
Integer
status
=
0
;
@ApiModelProperty
(
value
=
"接收方配发单"
)
private
List
<
FileRet
>
receiveFiles
;
}
dev-allot/src/main/java/com/tykj/dev/device/allot/subject/vo/AllotReceiveVo.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
allot
.
subject
.
vo
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
...
...
@@ -7,6 +8,7 @@ import lombok.Data;
import
javax.validation.constraints.Min
;
import
javax.validation.constraints.NotNull
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
...
...
@@ -63,4 +65,7 @@ public class AllotReceiveVo {
@NotNull
(
message
=
"status不能为空"
)
@ApiModelProperty
(
value
=
"是否缺失单据(0:否,1:是)"
)
private
Integer
status
=
0
;
@ApiModelProperty
(
value
=
"接收方配发单"
)
private
List
<
FileRet
>
receiveFiles
;
}
dev-allot/src/main/java/com/tykj/dev/device/allot/subject/vo/FileUploadVo.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
allot
.
subject
.
vo
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.validation.constraints.Min
;
import
javax.validation.constraints.NotNull
;
import
java.util.List
;
/**
* @author dengdiyi
...
...
@@ -33,4 +35,7 @@ public class FileUploadVo {
@ApiModelProperty
(
value
=
"接收单位B岗"
)
private
Integer
sendUserbId
;
@ApiModelProperty
(
value
=
"接收方配发单"
)
private
List
<
FileRet
>
receiveFiles
;
}
dev-confirmcheck/src/main/java/com/tykj/dev/device/confirmcheck/controller/DeviceCheckController.java
浏览文件 @
79e12293
...
...
@@ -117,13 +117,11 @@ public class DeviceCheckController {
@ApiOperation
(
value
=
"根据关键字分页查询核查统计数据"
)
@
Ge
tMapping
(
"/stat"
)
@
Pos
tMapping
(
"/stat"
)
public
Page
<
CheckStatTableVo
>
findStatByKeyword
(
@RequestParam
(
required
=
false
,
defaultValue
=
""
)
String
keyword
,
@RequestParam
(
required
=
false
,
defaultValue
=
"1"
)
int
page
,
@RequestParam
(
required
=
false
,
defaultValue
=
"10"
)
int
size
@RequestBody
CheckBillSelectVo
checkBillSelectVo
)
{
return
ccService
.
findAllStatTable
(
keyword
,
--
page
,
size
);
return
ccService
.
findAllStatTable
(
checkBillSelectVo
);
}
@ApiOperation
(
value
=
"根据id查询核查详情数据"
,
notes
=
"可以通过这个接口查询核查详情数据"
)
...
...
dev-confirmcheck/src/main/java/com/tykj/dev/device/confirmcheck/entity/vo/CheckBillSelectVo.java
0 → 100644
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
confirmcheck
.
entity
.
vo
;
import
com.tykj.dev.misc.base.CustomPage
;
import
io.swagger.annotations.ApiModel
;
import
lombok.Data
;
/**
* @author dengdiyi
*/
@Data
@ApiModel
(
"核查查询对象"
)
public
class
CheckBillSelectVo
extends
CustomPage
{
private
String
keyword
;
}
dev-confirmcheck/src/main/java/com/tykj/dev/device/confirmcheck/service/ConfirmCheckService.java
浏览文件 @
79e12293
...
...
@@ -5,6 +5,7 @@ import com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckBill;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckDetail
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckPeriod
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckStat
;
import
com.tykj.dev.device.confirmcheck.entity.vo.CheckBillSelectVo
;
import
com.tykj.dev.device.confirmcheck.entity.vo.CheckStatTableVo
;
import
org.springframework.data.domain.Page
;
...
...
@@ -22,13 +23,9 @@ public interface ConfirmCheckService {
/**
* 根据关键字查询报告列表
*
* @param keyword 要查询的字
* @param page 页码
* @param size 每页数据量
* @return {@link CheckStatTableVo} 's List
*/
Page
<
CheckStatTableVo
>
findAllStatTable
(
String
keyword
,
int
page
,
int
size
);
Page
<
CheckStatTableVo
>
findAllStatTable
(
CheckBillSelectVo
checkBillSelectVo
);
/**
* 开启自动核查
...
...
dev-confirmcheck/src/main/java/com/tykj/dev/device/confirmcheck/service/impl/ConfirmCheckServiceImpl.java
浏览文件 @
79e12293
...
...
@@ -5,11 +5,11 @@ import com.tykj.dev.blockcha.subject.entity.BcHash;
import
com.tykj.dev.blockcha.subject.service.BlockChainUtil
;
import
com.tykj.dev.device.confirmcheck.common.CheckType
;
import
com.tykj.dev.device.confirmcheck.common.TaskPeriod
;
import
com.tykj.dev.device.user.cache.AreaCache
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckBill
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckDetail
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckPeriod
;
import
com.tykj.dev.device.confirmcheck.entity.domain.DeviceCheckStat
;
import
com.tykj.dev.device.confirmcheck.entity.vo.CheckBillSelectVo
;
import
com.tykj.dev.device.confirmcheck.entity.vo.CheckDeviceStatVo
;
import
com.tykj.dev.device.confirmcheck.entity.vo.CheckStatTableVo
;
import
com.tykj.dev.device.confirmcheck.repository.DeviceCheckBillDao
;
...
...
@@ -23,6 +23,7 @@ import com.tykj.dev.device.library.subject.domin.DeviceLibrary;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
import
com.tykj.dev.device.task.subject.domin.Task
;
import
com.tykj.dev.device.user.cache.AreaCache
;
import
com.tykj.dev.device.user.subject.dao.AreaDao
;
import
com.tykj.dev.device.user.subject.dao.UnitsDao
;
import
com.tykj.dev.device.user.subject.entity.Area
;
...
...
@@ -30,6 +31,7 @@ import com.tykj.dev.device.user.subject.entity.Units;
import
com.tykj.dev.misc.exception.ApiException
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.MapperUtils
;
import
com.tykj.dev.misc.utils.PageUtil
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.jetbrains.annotations.NotNull
;
...
...
@@ -37,8 +39,6 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.boot.CommandLineRunner
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.data.domain.PageRequest
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler
;
import
org.springframework.scheduling.support.CronTrigger
;
...
...
@@ -300,21 +300,17 @@ public class ConfirmCheckServiceImpl implements ConfirmCheckService, CommandLine
/**
* 根据关键字查询报告列表
*
* @param keyword 要查询的字
* @param page 页码
* @param size 每页数据量
* @return {@link CheckStatTableVo} 's List
*/
@Override
public
Page
<
CheckStatTableVo
>
findAllStatTable
(
String
keyword
,
int
page
,
int
size
)
{
List
<
CheckStatTableVo
>
tableVos
=
statDao
.
findAll
().
stream
()
public
Page
<
CheckStatTableVo
>
findAllStatTable
(
CheckBillSelectVo
checkBillSelectVo
)
{
List
<
CheckStatTableVo
>
tableVos
=
statDao
.
findAll
(
checkBillSelectVo
.
getPageable
().
getSort
()
).
stream
()
.
filter
(
deviceCheckStat
->
!
"[]"
.
equals
(
deviceCheckStat
.
getStatInfo
()))
.
map
(
objTransUtil:
:
stat2TableVo
)
.
filter
(
vo
->
keywordFilter
(
vo
,
keyword
))
.
filter
(
vo
->
keywordFilter
(
vo
,
checkBillSelectVo
.
getKeyword
()
))
.
collect
(
Collectors
.
toList
());
return
new
PageImpl
<>(
tableVos
,
PageRequest
.
of
(
page
,
size
),
tableVos
.
siz
e
());
return
PageUtil
.
getPerPage
(
checkBillSelectVo
.
getPage
(),
checkBillSelectVo
.
getSize
(),
tableVos
,
checkBillSelectVo
.
getPageabl
e
());
}
...
...
dev-finalcheck/src/main/java/com/tykj/dev/device/finalcheck/controller/FinalCheckController.java
浏览文件 @
79e12293
...
...
@@ -5,19 +5,17 @@ import cn.afterturn.easypoi.excel.entity.TemplateExportParams;
import
com.tykj.dev.config.swagger.AutoDocument
;
import
com.tykj.dev.device.finalcheck.entity.dto.TimeParam
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalDetailVo
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportSelectVo
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportVo
;
import
com.tykj.dev.device.finalcheck.service.FinalCheckService
;
import
com.tykj.dev.misc.base.ResultObj
;
import
com.tykj.dev.misc.exception.ApiException
;
import
com.tykj.dev.misc.utils.ResultUtil
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.Tag
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.poi.ss.usermodel.Workbook
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.Page
;
import
org.springframework.format.annotation.DateTimeFormat
;
import
org.springframework.http.HttpHeaders
;
import
org.springframework.http.MediaType
;
import
org.springframework.http.ResponseEntity
;
...
...
@@ -25,13 +23,12 @@ import org.springframework.web.bind.annotation.*;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
java.io.BufferedOutputStream
;
import
java.io.ByteArrayOutputStream
;
import
java.io.IOException
;
import
java.
io.OutputStream
;
import
java.
text.SimpleDateFormat
;
import
java.
time.LocalDate
;
import
java.util.
*
;
import
java.
util.ArrayList
;
import
java.
util.HashMap
;
import
java.
util.List
;
import
java.util.
Map
;
import
static
com
.
tykj
.
dev
.
misc
.
utils
.
TimestampUtil
.
localDateToDate
;
...
...
@@ -51,17 +48,11 @@ public class FinalCheckController {
@Autowired
private
FinalCheckService
fcService
;
@
GetMapping
(
"/reports
"
)
@
PostMapping
(
"/reports/list
"
)
@ApiOperation
(
value
=
"查询所有决算报告(不附带详情数据)"
)
public
Page
<
FinalReportVo
>
findAllReports
(
@RequestParam
(
required
=
false
,
defaultValue
=
""
)
String
keyword
,
@RequestParam
(
required
=
false
)
@DateTimeFormat
(
iso
=
DateTimeFormat
.
ISO
.
DATE
,
pattern
=
"yyyy-MM-dd"
)
LocalDate
startTime
,
@RequestParam
(
required
=
false
)
@DateTimeFormat
(
iso
=
DateTimeFormat
.
ISO
.
DATE
,
pattern
=
"yyyy-MM-dd"
)
LocalDate
endTime
,
@RequestParam
(
required
=
false
,
defaultValue
=
"1"
)
int
page
,
@RequestParam
(
required
=
false
,
defaultValue
=
"10"
)
int
size
)
{
return
fcService
.
findAllWithoutDetail
(
keyword
,
--
page
,
size
,
startTime
,
endTime
);
@RequestBody
FinalReportSelectVo
finalReportSelectVo
)
{
return
fcService
.
findAllWithoutDetail
(
finalReportSelectVo
);
}
@GetMapping
(
"/{id}"
)
...
...
dev-finalcheck/src/main/java/com/tykj/dev/device/finalcheck/service/FinalCheckService.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
finalcheck
.
service
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportSelectVo
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportVo
;
import
org.springframework.data.domain.Page
;
...
...
@@ -24,15 +25,9 @@ public interface FinalCheckService {
/**
* 根据关键字查询报告列表(不附带detail)
*
* @param keyword 要查询的字
* @param page 页码
* @param size 每页数据量
* @param startTime 查询起始时间
* @param endTime 查询结束时间
* @return {@link FinalReportVo} 's List
*/
Page
<
FinalReportVo
>
findAllWithoutDetail
(
String
keyword
,
int
page
,
int
size
,
LocalDate
startTime
,
LocalDate
endTime
);
Page
<
FinalReportVo
>
findAllWithoutDetail
(
FinalReportSelectVo
finalReportSelectVo
);
/**
* 根据主键id查询报告
...
...
dev-finalcheck/src/main/java/com/tykj/dev/device/finalcheck/service/impl/FinalCheckServiceImpl.java
浏览文件 @
79e12293
...
...
@@ -3,6 +3,7 @@ package com.tykj.dev.device.finalcheck.service.impl;
import
com.github.wenhao.jpa.Specifications
;
import
com.tykj.dev.device.finalcheck.entity.domain.FinalDetail
;
import
com.tykj.dev.device.finalcheck.entity.domain.FinalReport
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportSelectVo
;
import
com.tykj.dev.device.finalcheck.entity.vo.FinalReportVo
;
import
com.tykj.dev.device.finalcheck.repisotry.FinalDetailDao
;
import
com.tykj.dev.device.finalcheck.repisotry.FinalReportDao
;
...
...
@@ -16,8 +17,6 @@ import com.tykj.dev.misc.exception.ApiException;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.PageRequest
;
import
org.springframework.data.domain.Sort
;
import
org.springframework.data.jpa.domain.Specification
;
import
org.springframework.stereotype.Service
;
...
...
@@ -29,7 +28,6 @@ import java.util.function.Function;
import
static
com
.
tykj
.
dev
.
misc
.
utils
.
TimestampUtil
.
localDateToDate
;
import
static
java
.
util
.
stream
.
Collectors
.
groupingBy
;
import
static
java
.
util
.
stream
.
Collectors
.
toMap
;
import
static
org
.
springframework
.
data
.
domain
.
Sort
.
Direction
.
ASC
;
/**
* FinalCheckServiceImpl.
...
...
@@ -93,21 +91,23 @@ public class FinalCheckServiceImpl implements FinalCheckService {
}
@Override
public
Page
<
FinalReportVo
>
findAllWithoutDetail
(
String
keyword
,
int
page
,
int
size
,
LocalDate
startTime
,
LocalDate
endTime
)
{
public
Page
<
FinalReportVo
>
findAllWithoutDetail
(
FinalReportSelectVo
finalReportSelectVo
)
{
LocalDate
startTime
=
finalReportSelectVo
.
getStartTime
();
LocalDate
endTime
=
finalReportSelectVo
.
getEndTime
();
String
keyword
=
finalReportSelectVo
.
getKeyword
();
boolean
timeQuery
=
Objects
.
nonNull
(
startTime
)
&&
Objects
.
nonNull
(
endTime
);
// 如果没有携带关键字且没有指定时间查询,则直接查询,否则添加时间条件
if
(
StringUtils
.
isEmpty
(
keyword
))
{
if
(
StringUtils
.
isEmpty
(
finalReportSelectVo
.
getKeyword
()
))
{
if
(
timeQuery
)
{
Specification
<
FinalReport
>
pred
=
Specifications
.<
FinalReport
>
and
()
.
gt
(
"startTime"
,
startTime
)
.
lt
(
"endTime"
,
endTime
)
.
build
();
return
reportDao
.
findAll
(
pred
,
PageRequest
.
of
(
page
,
size
,
Sort
.
by
(
ASC
,
"id"
)
))
return
reportDao
.
findAll
(
pred
,
finalReportSelectVo
.
getPageable
(
))
.
map
(
report
->
report
.
toVo
(
Collections
.
emptyList
()));
}
else
{
return
reportDao
.
findAll
(
PageRequest
.
of
(
page
,
size
,
Sort
.
by
(
ASC
,
"id"
)
))
return
reportDao
.
findAll
(
finalReportSelectVo
.
getPageable
(
))
.
map
(
report
->
report
.
toVo
(
Collections
.
emptyList
()));
}
}
else
{
...
...
@@ -122,7 +122,7 @@ public class FinalCheckServiceImpl implements FinalCheckService {
)
.
build
();
return
reportDao
.
findAll
(
pred
,
PageRequest
.
of
(
page
,
size
,
Sort
.
by
(
ASC
,
"id"
)
))
return
reportDao
.
findAll
(
pred
,
finalReportSelectVo
.
getPageable
(
))
.
map
(
report
->
report
.
toVo
(
Collections
.
emptyList
()));
}
...
...
dev-packing/src/main/java/com/tykj/dev/device/packing/service/impl/PackingLibraryServiceImpl.java
浏览文件 @
79e12293
...
...
@@ -250,6 +250,7 @@ public class PackingLibraryServiceImpl implements PackingLibraryService {
* 通过id逻辑删除该列装以及所有子列装
*/
@Override
@Transient
public
void
deleteAll
(
Integer
id
)
{
PackingLibrary
packingLibrary
=
getOne
(
id
);
if
(
deviceLibraryDao
.
getAllByPackingId
(
id
).
size
()>
0
){
...
...
dev-repair/src/main/java/com/tykj/dev/device/repair/controller/RepairBillSelectController.java
浏览文件 @
79e12293
...
...
@@ -33,10 +33,13 @@ import com.tykj.dev.misc.utils.ResultUtil;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.Page
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.*
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
/**
...
...
@@ -125,6 +128,7 @@ public class RepairBillSelectController {
@ApiOperation
(
value
=
"查询领取单"
,
notes
=
"可以通过这个接口查询领取单"
)
@PostMapping
(
value
=
"/archives/repairBack/summary"
)
public
ResponseEntity
selectRepairBackBill
(
@RequestBody
RepairBillSelectVo
repairBillSelectVo
)
{
Page
<
RepairBackBill
>
page
=
repairBackBillService
.
getPage
(
repairBillSelectVo
,
repairBillSelectVo
.
getPageable
());
return
ResultUtil
.
success
(
repairBackBillService
.
getPage
(
repairBillSelectVo
,
repairBillSelectVo
.
getPageable
()));
}
...
...
@@ -139,6 +143,7 @@ public class RepairBillSelectController {
//获取装备列表
RepairSendBill
repairSendBill
=
repairSendBillDao
.
findByDeviceRepairBillId
(
repairBill
.
getId
());
repairSendBill
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
repairSendBill
.
getSendFiles
()));
repairSendBill
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
repairSendBill
.
getReceiveFiles
()));
if
(
repairSendBill
.
getScriptJson
()!=
null
){
repairSendBill
.
setScripts
(
JacksonUtil
.
readValue
(
repairSendBill
.
getScriptJson
(),
new
TypeReference
<
List
<
ScriptSaveVo
>>()
{}));
}
...
...
@@ -196,6 +201,7 @@ public class RepairBillSelectController {
}
list
.
add
(
repairBackBill
);
repairBackBill
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
repairBackBill
.
getSendFiles
()));
repairBackBill
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
repairBackBill
.
getReceiveFiles
()));
List
<
DeviceLibrary
>
deviceLibraries
=
new
ArrayList
<>();
if
(
repairBackBill
.
getBackCheckDetail
()
!=
null
)
{
String
[]
strings1
=
repairBackBill
.
getBackCheckDetail
().
split
(
"x"
);
...
...
dev-repair/src/main/java/com/tykj/dev/device/repair/controller/RepairController.java
浏览文件 @
79e12293
差异被折叠。
点击展开。
dev-repair/src/main/java/com/tykj/dev/device/repair/subject/domin/RepairBackBill.java
浏览文件 @
79e12293
...
...
@@ -241,6 +241,9 @@ public class RepairBackBill {
@Column
(
name
=
"send_files"
,
columnDefinition
=
"TEXT"
)
private
String
sendFiles
;
@Column
(
name
=
"receive_files"
,
columnDefinition
=
"TEXT"
)
private
String
receiveFiles
;
@Column
(
name
=
"script_json"
,
columnDefinition
=
"TEXT"
)
private
String
scriptJson
;
...
...
@@ -249,4 +252,7 @@ public class RepairBackBill {
@Transient
private
List
<
FileRet
>
sendFileList
=
new
ArrayList
<>();
@Transient
private
List
<
FileRet
>
receiveFileList
=
new
ArrayList
<>();
}
dev-repair/src/main/java/com/tykj/dev/device/repair/subject/domin/RepairSendBill.java
浏览文件 @
79e12293
...
...
@@ -233,6 +233,9 @@ public class RepairSendBill {
@Column
(
name
=
"send_files"
,
columnDefinition
=
"TEXT"
)
private
String
sendFiles
;
@Column
(
name
=
"receive_files"
,
columnDefinition
=
"TEXT"
)
private
String
receiveFiles
;
@Column
(
name
=
"script_json"
,
columnDefinition
=
"TEXT"
)
private
String
scriptJson
;
...
...
@@ -241,4 +244,7 @@ public class RepairSendBill {
@Transient
private
List
<
FileRet
>
sendFileList
=
new
ArrayList
<>();
@Transient
private
List
<
FileRet
>
receiveFileList
=
new
ArrayList
<>();
}
dev-repair/src/main/java/com/tykj/dev/device/repair/subject/vo/FileUploadVo.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
repair
.
subject
.
vo
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.validation.constraints.Min
;
import
javax.validation.constraints.NotNull
;
import
java.util.List
;
/**
* @author dengdiyi
...
...
@@ -31,4 +33,6 @@ public class FileUploadVo {
@ApiModelProperty
(
value
=
"是否上传单据(0:否,1:是)"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"接收方配发单"
)
private
List
<
FileRet
>
receiveFiles
;
}
dev-repair/src/main/java/com/tykj/dev/device/repair/subject/vo/FileVo.java
浏览文件 @
79e12293
...
...
@@ -24,7 +24,13 @@ public class FileVo {
@ApiModelProperty
(
value
=
"领取单附件"
)
private
List
<
FileRet
>
sendFiles
;
@NotNull
(
message
=
"status不能为空"
)
//
@NotNull(message = "status不能为空")
@ApiModelProperty
(
value
=
"是否上传单据(0:否,1:是)"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"接收单位A岗"
)
private
Integer
receiveUseraId
;
@ApiModelProperty
(
value
=
"接收单位B岗"
)
private
Integer
receiveUserbId
;
}
dev-repair/src/main/java/com/tykj/dev/device/repair/subject/vo/RepairReceiveVo.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
repair
.
subject
.
vo
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
...
...
@@ -67,4 +68,8 @@ public class RepairReceiveVo {
@ApiModelProperty
(
value
=
"维修装备详情列表"
)
private
List
<
DeviceDetailVo
>
deviceList
=
new
ArrayList
<>();
@ApiModelProperty
(
value
=
"接收方配发单"
)
private
List
<
FileRet
>
receiveFiles
;
}
dev-selfcheck/src/main/java/com/tykj/dev/device/selfcheck/controller/SelfCheckController.java
浏览文件 @
79e12293
...
...
@@ -262,6 +262,27 @@ public class SelfCheckController {
return
ResultUtil
.
success
(
compareResultVo
);
}
@ApiOperation
(
value
=
"生成自查待办"
,
notes
=
"可以通过这个接口生成自查待办"
)
@GetMapping
(
value
=
"/create/{type}"
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
ResponseEntity
createTask
(
@PathVariable
(
"type"
)
int
type
){
String
message
=
type
==
0
?
"手动"
:
"扫码"
;
String
message2
=
type
==
0
?
"手动"
:
"终端"
;
String
unitName
=
userUtils
.
getCurrentUserUnitName
();
SelfCheckBill
selfCheckBill
=
new
SelfCheckBill
();
selfCheckBill
.
setCheckStatus
(
3
);
selfCheckBill
.
setCheckUnit
(
unitName
);
selfCheckBill
.
setTitle
(
unitName
+
"发起的"
+
message2
+
"自查任务"
);
SelfCheckBill
selfCheckBill1
=
selfExaminationBillService
.
addEntity
(
selfCheckBill
);
//发起待自查任务
List
<
Integer
>
userIds
=
new
ArrayList
<>();
userIds
.
add
(
userUtils
.
getCurrentUserId
());
TaskBto
taskBto
=
new
TaskBto
(
StatusEnum
.
WAIT_SELF_CHECK
.
id
,
"自查业务"
,
null
,
"."
,
selfCheckBill1
.
getId
(),
4
,
userUtils
.
getCurrentUnitId
(),
0
,
message
,
userIds
);
TaskBto
taskBto1
=
taskService
.
start
(
taskBto
);
return
ResponseEntity
.
ok
(
taskBto1
.
getId
());
}
@ApiOperation
(
value
=
"发起自查业务"
,
notes
=
"可以通过这个接口发起自查业务"
)
@PostMapping
(
value
=
"/addBill"
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
...
...
dev-statistical/src/main/java/com/tykj/dev/statistical/controller/StatisticalController.java
浏览文件 @
79e12293
...
...
@@ -13,17 +13,21 @@ import com.tykj.dev.device.library.service.DeviceLibraryService;
import
com.tykj.dev.device.library.subject.domin.DeviceLibrary
;
import
com.tykj.dev.device.library.subject.vo.DeviceLibrarySelectVo
;
import
com.tykj.dev.misc.exception.ApiException
;
import
com.tykj.dev.misc.utils.PageUtil
;
import
com.tykj.dev.misc.utils.ResultUtil
;
import
com.tykj.dev.statistical.cache.StatisticalCache
;
import
com.tykj.dev.statistical.service.StatisticalService
;
import
com.tykj.dev.statistical.vo.DeviceStatistics
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.Page
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
java.text.ParseException
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
...
...
@@ -45,6 +49,9 @@ public class StatisticalController {
@Autowired
private
DeviceLibraryService
deviceLibraryService
;
// @Autowired
// private ConfigCache configCache;
/**
* 查询各市的装备数量
* @return 各市装备对象集合
...
...
@@ -179,7 +186,18 @@ public class StatisticalController {
@PostMapping
(
"/device"
)
public
ResponseEntity
selectAllDeviceStatList
(
@RequestBody
DeviceLibrarySelectVo
deviceLibrarySelectVo
)
{
List
<
DeviceLibrary
>
deviceLibraryEntities
=
deviceLibraryService
.
getAllList
(
deviceLibrarySelectVo
);
return
ResponseEntity
.
ok
(
getDeviceStatistics
(
deviceLibraryEntities
));
deviceLibraryEntities
.
forEach
(
DeviceLibrary:
:
setConfigName
);
Page
<
DeviceLibrary
>
deviceLibraries
=
PageUtil
.
getPerPage
(
deviceLibrarySelectVo
.
getPage
(),
deviceLibrarySelectVo
.
getSize
(),
deviceLibraryEntities
,
deviceLibrarySelectVo
.
getPageable
());
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
// Map<Integer,String> lifeStatusMap = configCache.getLifeStatusMap();
// Set<Integer> status = deviceLibraryEntities.stream().map(DeviceLibrary::getLifeStatus).collect(Collectors.toSet());
map
.
put
(
"pages"
,
deviceLibraries
);
map
.
put
(
"models"
,
deviceLibraryEntities
.
stream
().
map
(
DeviceLibrary:
:
getModel
).
collect
(
Collectors
.
toSet
()));
map
.
put
(
"names"
,
deviceLibraryEntities
.
stream
().
map
(
DeviceLibrary:
:
getName
).
collect
(
Collectors
.
toSet
()));
// map.put("ownUnits",deviceLibraryEntities.stream().map(DeviceLibrary::getOwnUnit).collect(Collectors.toSet()));
// map.put("locationUnits",deviceLibraryEntities.stream().map(DeviceLibrary::getLocationUnit).collect(Collectors.toSet()));
// map.put("lifeStatus",status.stream().map(integer -> new LifeStatusVo(integer,lifeStatusMap.get(integer))).collect(Collectors.toList()));
return
ResultUtil
.
success
(
map
);
}
/**
...
...
dev-storage/src/main/java/com/tykj/dev/device/storage/controller/StorageBillController.java
浏览文件 @
79e12293
...
...
@@ -14,10 +14,7 @@ import com.tykj.dev.device.packing.service.PackingLibraryService;
import
com.tykj.dev.device.packing.subject.domin.PackingLibrary
;
import
com.tykj.dev.device.storage.service.StorageBillService
;
import
com.tykj.dev.device.storage.subject.domin.StorageBill
;
import
com.tykj.dev.device.storage.subject.vo.StorageBillConfirmVo
;
import
com.tykj.dev.device.storage.subject.vo.StorageBillDetailVo
;
import
com.tykj.dev.device.storage.subject.vo.StorageBillSaveVo
;
import
com.tykj.dev.device.storage.subject.vo.StorageDetailVo
;
import
com.tykj.dev.device.storage.subject.vo.*
;
import
com.tykj.dev.device.task.service.TaskLogService
;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
...
...
@@ -416,21 +413,21 @@ public class StorageBillController {
storageBillEntity
.
setReceiveUserA
(
userPublicService
.
getOne
(
storageBillEntity
.
getReceiveUseraId
()).
getName
());
storageBillEntity
.
setReceiveUserB
(
userPublicService
.
getOne
(
storageBillEntity
.
getReceiveUserbId
()).
getName
());
storageBillEntity
.
setReplyFileList
(
FilesUtil
.
stringFileToList
(
storageBillEntity
.
getReplyFiles
()));
List
<
StorageBillDetail
Vo
>
storageBillDetailVos
=
JacksonUtil
.
readValue
(
storageBillEntity
.
getPackingDetail
(),
new
TypeReference
<
List
<
StorageBillDetailVo
>>()
{
List
<
StorageBillDetail
>
storageBillDetails
=
JacksonUtil
.
readValue
(
storageBillEntity
.
getPackingDetail
(),
new
TypeReference
<
List
<
StorageBillDetail
>>()
{
});
if
(
storageBillDetailVos
!=
null
)
{
setPackingLibrary
(
storageBillDetailVos
);
}
storageBillEntity
.
setStorageBillDetail
Vos
(
storageBillDetailVo
s
);
//
if (storageBillDetailVos != null) {
//
setPackingLibrary(storageBillDetailVos);
//
}
storageBillEntity
.
setStorageBillDetail
s
(
storageBillDetail
s
);
return
ResponseEntity
.
ok
(
storageBillEntity
);
}
private
void
setPackingLibrary
(
List
<
StorageBillDetailVo
>
storageBillDetailVos
){
storageBillDetailVos
.
forEach
(
storageBillDetailVo
->
{
storageBillDetailVo
.
setPackingLibrary
(
packingLibraryService
.
getOne
(
storageBillDetailVo
.
getPackingId
()));
if
(
storageBillDetailVo
.
getList
()!=
null
&&
storageBillDetailVo
.
getList
().
size
()>
0
){
setPackingLibrary
(
storageBillDetailVo
.
getList
());
}
});
}
//
private void setPackingLibrary(List<StorageBillDetailVo> storageBillDetailVos){
//
storageBillDetailVos.forEach(storageBillDetailVo -> {
//
storageBillDetailVo.setPackingLibrary(packingLibraryService.getOne(storageBillDetailVo.getPackingId()));
//
if (storageBillDetailVo.getList()!=null&&storageBillDetailVo.getList().size()>0){
//
setPackingLibrary(storageBillDetailVo.getList());
//
}
//
});
//
}
}
dev-storage/src/main/java/com/tykj/dev/device/storage/subject/domin/StorageBill.java
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
storage
.
subject
.
domin
;
import
com.tykj.dev.device.file.entity.FileRet
;
import
com.tykj.dev.device.storage.subject.vo.StorageBillDetail
Vo
;
import
com.tykj.dev.device.storage.subject.vo.StorageBillDetail
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
...
...
@@ -160,7 +160,7 @@ public class StorageBill {
@ApiModelProperty
(
value
=
"列装详情"
)
@Transient
private
List
<
StorageBillDetail
Vo
>
storageBillDetailVo
s
=
new
ArrayList
<>();
private
List
<
StorageBillDetail
>
storageBillDetail
s
=
new
ArrayList
<>();
@ApiModelProperty
(
value
=
"区块链记录id"
)
private
String
recordId
;
...
...
dev-storage/src/main/java/com/tykj/dev/device/storage/subject/vo/StorageBillDetail.java
0 → 100644
浏览文件 @
79e12293
package
com
.
tykj
.
dev
.
device
.
storage
.
subject
.
vo
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.util.List
;
/**
* @author dengdiyi
*/
@Data
@ApiModel
(
"入库详情类"
)
public
class
StorageBillDetail
{
@ApiModelProperty
(
value
=
"配件列表"
)
List
<
StorageBillDetail
>
childs
;
@ApiModelProperty
(
value
=
"列装id"
)
private
Integer
id
;
@ApiModelProperty
(
value
=
"入库数量"
)
private
Integer
number
;
@ApiModelProperty
(
value
=
"序列号区间"
)
private
String
seqInterval
;
@ApiModelProperty
(
value
=
"生产号区间"
)
private
String
prodInterval
;
@ApiModelProperty
(
value
=
"型号"
)
private
String
model
;
@ApiModelProperty
(
value
=
"名称"
)
private
String
name
;
@ApiModelProperty
(
value
=
"形态"
)
private
String
typeName
;
}
dev-storage/src/main/java/com/tykj/dev/device/storage/subject/vo/StorageBillSaveVo.java
浏览文件 @
79e12293
...
...
@@ -101,7 +101,7 @@ public class StorageBillSaveVo {
private
List
<
DeviceLibrarySaveVo
>
deviceLibrarySaveVoList
=
new
ArrayList
<>();
@ApiModelProperty
(
value
=
"入库列装详情"
)
private
List
<
StorageBillDetail
Vo
>
storageBillDetailVo
s
=
new
ArrayList
<>();
private
List
<
StorageBillDetail
>
storageBillDetail
s
=
new
ArrayList
<>();
public
StorageBill
toDo
()
{
//modelMap复制
...
...
@@ -109,7 +109,7 @@ public class StorageBillSaveVo {
StorageBill
storageBillEntity
=
mapper
.
map
(
this
,
StorageBill
.
class
);
storageBillEntity
.
setStorageStatus
(
2
);
storageBillEntity
.
setStorageDetail
(
"x"
);
storageBillEntity
.
setPackingDetail
(
JacksonUtil
.
toJSon
(
storageBillDetail
Vo
s
));
storageBillEntity
.
setPackingDetail
(
JacksonUtil
.
toJSon
(
storageBillDetails
));
if
(
this
.
replyFiles
!=
null
&&
this
.
replyFiles
.
size
()>
0
){
storageBillEntity
.
setReplyFiles
(
FilesUtil
.
stringFileToList
(
this
.
replyFiles
));
}
...
...
dev-taskselect/src/main/java/com/tykj/dev/device/taskselect/controller/TaskSelectController.java
浏览文件 @
79e12293
...
...
@@ -193,6 +193,7 @@ public class TaskSelectController {
allotBillEntity
.
setReplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReplyFiles
()));
allotBillEntity
.
setApplyFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getApplyFiles
()));
allotBillEntity
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getSendFiles
()));
allotBillEntity
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
allotBillEntity
.
getReceiveFiles
()));
if
(
allotBillEntity
.
getSendUseraId
()
!=
null
)
{
allotBillEntity
.
setSenderUserA
(
userPublicService
.
getOne
(
allotBillEntity
.
getSendUseraId
()).
getName
());
}
...
...
@@ -260,6 +261,7 @@ public class TaskSelectController {
allotBackBill
.
setReceiveUserB
(
userPublicService
.
getOne
(
allotBackBill
.
getReceiveUserbId
()).
getName
());
}
allotBackBill
.
setSendFileList
(
FilesUtil
.
stringFileToList
(
allotBackBill
.
getSendFiles
()));
allotBackBill
.
setReceiveFileList
(
FilesUtil
.
stringFileToList
(
allotBackBill
.
getReceiveFiles
()));
allotBackBill
.
setReplyFileList
(
FilesUtil
.
stringFileToList
(
allotBackBill
.
getReplyFiles
()));
allotBackBill
.
setApplyFileList
(
FilesUtil
.
stringFileToList
(
allotBackBill
.
getApplyFiles
()));
if
(
allotBackBill
.
getScriptJson
()!=
null
){
...
...
dev-union/src/main/java/com/tykj/dev/union/LogAspect.java
浏览文件 @
79e12293
...
...
@@ -287,9 +287,12 @@ public class LogAspect {
// }
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
ALLOTING
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
))
||
(
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_ALLOT_RECEIVE_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
if
(
allotBill
.
getBillFileName
()!=
null
&&
allotBill
.
getBillFileUrl
()!=
null
)
{
this
.
fileVos
.
add
(
new
FileVo
(
"配发单"
,
allotBill
.
getBillFileName
(),
allotBill
.
getBillFileUrl
()));
}
// if (allotBill.getBillFileName()!=null&&allotBill.getBillFileUrl()!=null) {
// this.fileVos.add(new FileVo("配发单", allotBill.getBillFileName(), allotBill.getBillFileUrl()));
// }
FilesUtil
.
stringFileToList
(
allotBill
.
getReceiveFiles
()).
forEach
(
fileRet
->
{
this
.
fileVos
.
add
(
new
FileVo
(
"配发单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
// this.fileVos.add(new FileVo("入库确认单", allotBill.getReceiveFileName(), allotBill.getReceiveFileUrl()));
}
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_ALLOT_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
))
...
...
@@ -310,9 +313,12 @@ public class LogAspect {
// }
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
ALLOT_BACKING
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
))
||
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_ALLOT_BACK_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
))
{
if
(
allotBackBill
.
getBillFileName
()!=
null
&&
allotBackBill
.
getBillFileUrl
()!=
null
)
{
this
.
fileVos
.
add
(
new
FileVo
(
"退回单"
,
allotBackBill
.
getBillFileName
(),
allotBackBill
.
getBillFileUrl
()));
}
// if (allotBackBill.getBillFileName()!=null&&allotBackBill.getBillFileUrl()!=null) {
// this.fileVos.add(new FileVo("退回单", allotBackBill.getBillFileName(), allotBackBill.getBillFileUrl()));
// }
FilesUtil
.
stringFileToList
(
allotBackBill
.
getReceiveFiles
()).
forEach
(
fileRet
->
{
this
.
fileVos
.
add
(
new
FileVo
(
"退回单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
// this.fileVos.add(new FileVo("入库确认单", allotBackBill.getReceiveFileName(), allotBackBill.getReceiveFileUrl()));
}
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_BACK_FILE_2
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
...
...
@@ -353,18 +359,24 @@ public class LogAspect {
// this.fileVos.add(new FileVo("出库确认单", repairSendBill.getFileName(), repairSendBill.getFileUrl()));
// }
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_RECEIVE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
if
(
repairSendBill
.
getBillFileName
()!=
null
&&
repairSendBill
.
getBillFileUrl
()!=
null
)
{
this
.
fileVos
.
add
(
new
FileVo
(
"维修单"
,
repairSendBill
.
getBillFileName
(),
repairSendBill
.
getBillFileUrl
()));
}
// if (repairSendBill.getBillFileName()!=null&&repairSendBill.getBillFileUrl()!=null) {
// this.fileVos.add(new FileVo("维修单", repairSendBill.getBillFileName(), repairSendBill.getBillFileUrl()));
// }
FilesUtil
.
stringFileToList
(
repairSendBill
.
getReceiveFiles
()).
forEach
(
fileRet
->
{
this
.
fileVos
.
add
(
new
FileVo
(
"维修单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
// this.fileVos.add(new FileVo("入库确认单", repairSendBill.getReceiveFileName(), repairSendBill.getReceiveFileUrl()));
}
// if ((this.oldStatus.equals(StatusEnum.WAIT_RECEIVE.id) && this.newStatus.equals(StatusEnum.WAIT_UPLOAD_FILE.id))) {
// this.fileVos.add(new FileVo("入库确认单", repairSendBill.getReceiveFileName(), repairSendBill.getReceiveFileUrl()));
// }
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
if
(
repairSendBill
.
getBillFileName
()!=
null
&&
repairSendBill
.
getBillFileUrl
()!=
null
)
{
this
.
fileVos
.
add
(
new
FileVo
(
"维修单"
,
repairSendBill
.
getBillFileName
(),
repairSendBill
.
getBillFileUrl
()));
}
// if (repairSendBill.getBillFileName()!=null&&repairSendBill.getBillFileUrl()!=null) {
// this.fileVos.add(new FileVo("维修单", repairSendBill.getBillFileName(), repairSendBill.getBillFileUrl()));
// }
FilesUtil
.
stringFileToList
(
repairSendBill
.
getReceiveFiles
()).
forEach
(
fileRet
->
{
this
.
fileVos
.
add
(
new
FileVo
(
"维修单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
}
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_SEND_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
FilesUtil
.
stringFileToList
(
repairSendBill
.
getSendFiles
()).
forEach
(
fileRet
->
{
...
...
@@ -423,9 +435,12 @@ public class LogAspect {
// this.fileVos.add(new FileVo("出库确认单", repairBackBill.getFileName(), repairBackBill.getFileUrl()));
// }
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_BACK_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
if
(
repairBackBill
.
getBillFileName
()!=
null
&&
repairBackBill
.
getBillFileUrl
()!=
null
)
{
this
.
fileVos
.
add
(
new
FileVo
(
"领取单"
,
repairBackBill
.
getBillFileName
(),
repairBackBill
.
getBillFileUrl
()));
}
// if (repairBackBill.getBillFileName()!=null&&repairBackBill.getBillFileUrl()!=null) {
// this.fileVos.add(new FileVo("领取单", repairBackBill.getBillFileName(), repairBackBill.getBillFileUrl()));
// }
FilesUtil
.
stringFileToList
(
repairBackBill
.
getReceiveFiles
()).
forEach
(
fileRet
->
{
this
.
fileVos
.
add
(
new
FileVo
(
"领取单"
,
fileRet
.
getName
(),
fileRet
.
getPreviewPath
()));
});
}
if
((
this
.
oldStatus
.
equals
(
StatusEnum
.
WAIT_UPLOAD_BACK_SEND_FILE
.
id
)
&&
this
.
newStatus
.
equals
(
StatusEnum
.
END
.
id
)))
{
FilesUtil
.
stringFileToList
(
repairBackBill
.
getSendFiles
()).
forEach
(
fileRet
->
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论