Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
9276e8c2
提交
9276e8c2
authored
12月 04, 2020
作者:
邓砥奕
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改bug
上级
f93d7bd7
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
29 行增加
和
9 行删除
+29
-9
PackingLibraryUpdateVo.java
...dev/device/packing/subject/vo/PackingLibraryUpdateVo.java
+0
-9
TaskLogService.java
...java/com/tykj/dev/device/task/service/TaskLogService.java
+7
-0
TaskLogServiceImpl.java
...tykj/dev/device/task/service/impl/TaskLogServiceImpl.java
+22
-0
没有找到文件。
dev-packing/src/main/java/com/tykj/dev/device/packing/subject/vo/PackingLibraryUpdateVo.java
浏览文件 @
9276e8c2
...
...
@@ -27,7 +27,6 @@ public class PackingLibraryUpdateVo {
@ApiModelProperty
(
value
=
"名称"
,
example
=
"测试名称"
)
private
String
name
;
@NotNull
(
message
=
"applyType不能为空"
)
@ApiModelProperty
(
value
=
"应用类型"
,
example
=
"1"
)
private
Integer
applyType
;
...
...
@@ -35,7 +34,6 @@ public class PackingLibraryUpdateVo {
@ApiModelProperty
(
value
=
"密级"
,
example
=
"1"
)
private
Integer
secretLevel
;
@NotNull
(
message
=
"matchingRange不能为空"
)
@ApiModelProperty
(
value
=
"配用范围"
,
example
=
"1"
)
private
Integer
matchingRange
;
...
...
@@ -55,15 +53,12 @@ public class PackingLibraryUpdateVo {
@ApiModelProperty
(
value
=
"列装状态"
,
example
=
"1"
)
private
Integer
status
;
@NotNull
(
message
=
"nature不能为空"
)
@ApiModelProperty
(
value
=
"列装性质"
,
example
=
"1"
)
private
Integer
nature
;
@NotNull
(
message
=
"prodUnit不能为空"
)
@ApiModelProperty
(
value
=
"生产单位"
,
example
=
"测试型号"
)
private
String
prodUnit
;
@NotNull
(
message
=
"createUnit不能为空"
)
@ApiModelProperty
(
value
=
"创建单位"
,
example
=
"测试创建单位"
)
private
String
createUnit
;
...
...
@@ -71,19 +66,15 @@ public class PackingLibraryUpdateVo {
@ApiModelProperty
(
value
=
"价格"
,
example
=
"2.000.000"
)
private
String
price
;
@NotNull
(
message
=
"imageName不能为空"
)
@ApiModelProperty
(
value
=
"照片名称"
,
example
=
"没有先填一个空格"
)
private
String
imageName
;
@NotNull
(
message
=
"imageUrl不能为空"
)
@ApiModelProperty
(
value
=
"照片路径"
,
example
=
"没有先填一个空格"
)
private
String
imageUrl
;
@NotNull
(
message
=
"fileName不能为空"
)
@ApiModelProperty
(
value
=
"附件名称"
,
example
=
"没有先填一个空格"
)
private
String
fileName
;
@NotNull
(
message
=
"fileUrl不能为空"
)
@ApiModelProperty
(
value
=
"附件路径"
,
example
=
"没有先填一个空格"
)
private
String
fileUrl
;
...
...
dev-task/src/main/java/com/tykj/dev/device/task/service/TaskLogService.java
浏览文件 @
9276e8c2
...
...
@@ -2,6 +2,7 @@ package com.tykj.dev.device.task.service;
import
com.tykj.dev.device.task.subject.bto.TaskLogBto
;
import
com.tykj.dev.device.task.subject.vo.TaskLogSelectVo
;
import
com.tykj.dev.device.task.subject.vo.TaskLogUserVo
;
import
java.util.List
;
...
...
@@ -23,4 +24,10 @@ public interface TaskLogService {
* 获取业务日志
*/
List
<
TaskLogUserVo
>
getByTaskId
(
Integer
taskId
);
/**
* @param taskLogSelectVo 查询vo
* 获取所有业务操作日志
*/
List
<
TaskLogUserVo
>
getAllByTime
(
TaskLogSelectVo
taskLogSelectVo
);
}
dev-task/src/main/java/com/tykj/dev/device/task/service/impl/TaskLogServiceImpl.java
浏览文件 @
9276e8c2
...
...
@@ -4,6 +4,7 @@ import com.tykj.dev.device.task.repository.TaskLogDao;
import
com.tykj.dev.device.task.service.TaskLogService
;
import
com.tykj.dev.device.task.subject.bto.TaskLogBto
;
import
com.tykj.dev.device.task.subject.domin.TaskLog
;
import
com.tykj.dev.device.task.subject.vo.TaskLogSelectVo
;
import
com.tykj.dev.device.task.subject.vo.TaskLogUserVo
;
import
com.tykj.dev.device.task.utils.TaskUtils
;
import
com.tykj.dev.misc.exception.ApiException
;
...
...
@@ -11,6 +12,7 @@ import com.tykj.dev.misc.utils.ResultUtil;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.Comparator
;
import
java.util.List
;
import
java.util.Optional
;
import
java.util.stream.Collectors
;
...
...
@@ -54,4 +56,24 @@ public class TaskLogServiceImpl implements TaskLogService {
return
taskLogs
.
stream
().
map
(
TaskLog:
:
parse2bto
).
map
(
TaskLogBto:
:
toVo
).
collect
(
Collectors
.
toList
());
}
/**
* @param taskLogSelectVo 查询vo
* 获取所有业务操作日志
*/
@Override
public
List
<
TaskLogUserVo
>
getAllByTime
(
TaskLogSelectVo
taskLogSelectVo
)
{
List
<
TaskLogUserVo
>
taskLogUserVos
=
taskLogDao
.
findAll
().
stream
().
map
(
TaskLog:
:
parse2bto
).
map
(
TaskLogBto:
:
toVo
).
collect
(
Collectors
.
toList
());
if
(
taskLogSelectVo
!=
null
&&
taskLogSelectVo
.
getStartTime
()!=
null
&&
taskLogSelectVo
.
getEndTime
()!=
null
){
return
taskLogUserVos
.
stream
()
.
filter
(
taskLogUserVo
->
taskLogUserVo
.
getCreateTime
().
after
(
taskLogSelectVo
.
getStartTime
())&&
taskLogUserVo
.
getCreateTime
().
before
(
taskLogSelectVo
.
getEndTime
()))
.
sorted
(
Comparator
.
comparing
(
TaskLogUserVo:
:
getCreateTime
).
reversed
())
.
collect
(
Collectors
.
toList
());
}
else
{
return
taskLogUserVos
.
stream
()
.
sorted
(
Comparator
.
comparing
(
TaskLogUserVo:
:
getCreateTime
).
reversed
())
.
collect
(
Collectors
.
toList
());
}
}
}
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论