Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
byit-myth-job
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liyuan
byit-myth-job
Commits
891fc8b5
Commit
891fc8b5
authored
Jul 24, 2020
by
huangfusuper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加查询标识
parent
ca4b27e2
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
33 additions
and
7 deletions
+33
-7
ApiFlowStatusServiceImpl.java
.../java/com/byit/service/impl/ApiFlowStatusServiceImpl.java
+12
-7
FlowEntityCoreDto.java
...in-core/src/main/java/com/byit/dto/FlowEntityCoreDto.java
+4
-0
FlowStatusCoreDto.java
...in-core/src/main/java/com/byit/dto/FlowStatusCoreDto.java
+4
-0
RunRecordingMapper.xml
...min-core/src/main/resources/mapper/RunRecordingMapper.xml
+1
-0
JavaCallbackLogDto.java
...re/src/main/java/com/byit/dto/api/JavaCallbackLogDto.java
+2
-0
JobStatusDto.java
...-core/src/main/java/com/byit/dto/plugin/JobStatusDto.java
+5
-0
JobStatusResultDto.java
...src/main/java/com/byit/dto/plugin/JobStatusResultDto.java
+5
-0
No files found.
byit-myth-admin/src/main/java/com/byit/service/impl/ApiFlowStatusServiceImpl.java
View file @
891fc8b5
...
@@ -60,19 +60,24 @@ public class ApiFlowStatusServiceImpl implements ApiFlowStatusService {
...
@@ -60,19 +60,24 @@ public class ApiFlowStatusServiceImpl implements ApiFlowStatusService {
FlowEntityCoreDto
flowEntityCoreDto
=
new
FlowEntityCoreDto
();
FlowEntityCoreDto
flowEntityCoreDto
=
new
FlowEntityCoreDto
();
flowEntityCoreDto
.
setFlowName
(
jobStatus
.
getJobName
());
flowEntityCoreDto
.
setFlowName
(
jobStatus
.
getJobName
());
flowEntityCoreDto
.
setScheduleType
(
jobStatus
.
getScheduleType
().
getCode
());
flowEntityCoreDto
.
setScheduleType
(
jobStatus
.
getScheduleType
().
getCode
());
if
(
StringUtils
.
isNoneBlank
(
jobStatus
.
getHasMark
()))
{
flowEntityCoreDto
.
setStartTime
(
0L
);
flowEntityCoreDto
.
setEndTime
(
999999999999999L
);
}
else
{
flowEntityCoreDto
.
setStartTime
(
DateUtil
.
getThisDayStartDate
().
getTime
());
flowEntityCoreDto
.
setEndTime
(
DateUtil
.
getThisDayEndDate
().
getTime
());
}
return
flowEntityCoreDto
;
return
flowEntityCoreDto
;
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
flowStatusCoreDto
.
setFlowEntityCoreDtos
(
flowEntityCoreDtos
);
flowStatusCoreDto
.
setFlowEntityCoreDtos
(
flowEntityCoreDtos
);
//查询对应条件的实例
//查询对应条件的实例
if
(
flowStatusCoreDto
!=
null
)
{
if
(
CollectionUtil
.
isNotEmpty
(
flowStatusCoreDto
.
getFlowEntityCoreDtos
()
)
)
{
List
<
RunRecording
>
byFlowName
AndTypeAndWId
=
runRecordingMapper
.
findByFlowNameAndTypeAndWId
(
flowStatusCoreDto
);
List
<
RunRecording
>
byFlowName
=
runRecordingMapper
.
findByFlowNameAndTypeAndWId
(
flowStatusCoreDto
);
if
(
CollectionUtil
.
isNotEmpty
(
byFlowNameAndTypeAndWId
))
{
if
(
CollectionUtil
.
isNotEmpty
(
byFlowName
))
{
//筛选当天数据
if
(
CollectionUtil
.
isNotEmpty
(
byFlowName
))
{
List
<
RunRecording
>
collect
=
byFlowNameAndTypeAndWId
.
stream
().
filter
(
byFlowName
->
byFlowName
.
getTriggerTime
()
>
DateUtil
.
getThisDayStartDate
().
getTime
()
&&
byFlowName
.
getTriggerTime
()
<=
DateUtil
.
getThisDayEndDate
().
getTime
()).
collect
(
Collectors
.
toList
());
byFlowName
.
forEach
(
byFlowNameAndType
->{
if
(
CollectionUtil
.
isNotEmpty
(
collect
))
{
collect
.
forEach
(
byFlowNameAndType
->{
JobStatusResultDto
jobStatusResultDto
=
new
JobStatusResultDto
();
JobStatusResultDto
jobStatusResultDto
=
new
JobStatusResultDto
();
jobStatusResultDto
.
setFindDateTime
(
System
.
currentTimeMillis
());
jobStatusResultDto
.
setFindDateTime
(
System
.
currentTimeMillis
());
Date
endTime
=
byFlowNameAndType
.
getEndTime
();
Date
endTime
=
byFlowNameAndType
.
getEndTime
();
...
...
byit-myth-core/myth-admin-core/src/main/java/com/byit/dto/FlowEntityCoreDto.java
View file @
891fc8b5
...
@@ -16,4 +16,8 @@ import java.io.Serializable;
...
@@ -16,4 +16,8 @@ import java.io.Serializable;
public
class
FlowEntityCoreDto
implements
Serializable
{
public
class
FlowEntityCoreDto
implements
Serializable
{
private
String
flowName
;
private
String
flowName
;
private
Integer
scheduleType
;
private
Integer
scheduleType
;
private
Long
startTime
;
private
Long
endTime
;
}
}
byit-myth-core/myth-admin-core/src/main/java/com/byit/dto/FlowStatusCoreDto.java
View file @
891fc8b5
...
@@ -18,6 +18,10 @@ import java.util.List;
...
@@ -18,6 +18,10 @@ import java.util.List;
public
class
FlowStatusCoreDto
implements
Serializable
{
public
class
FlowStatusCoreDto
implements
Serializable
{
private
Integer
workspaceId
;
private
Integer
workspaceId
;
/**
* 查询全部的标记
*/
private
String
hasMark
;
private
List
<
FlowEntityCoreDto
>
flowEntityCoreDtos
;
private
List
<
FlowEntityCoreDto
>
flowEntityCoreDtos
;
...
...
byit-myth-core/myth-admin-core/src/main/resources/mapper/RunRecordingMapper.xml
View file @
891fc8b5
...
@@ -212,6 +212,7 @@
...
@@ -212,6 +212,7 @@
<if
test=
"flowStatusCoreDtos != null"
>
<if
test=
"flowStatusCoreDtos != null"
>
<foreach
collection=
"flowStatusCoreDtos.flowEntityCoreDtos"
item=
"flowEntityCoreDto"
separator=
" or "
open=
"("
close=
")"
>
<foreach
collection=
"flowStatusCoreDtos.flowEntityCoreDtos"
item=
"flowEntityCoreDto"
separator=
" or "
open=
"("
close=
")"
>
flow_name = #{flowEntityCoreDto.flowName} and schedule_type = #{flowEntityCoreDto.scheduleType}
flow_name = #{flowEntityCoreDto.flowName} and schedule_type = #{flowEntityCoreDto.scheduleType}
and trigger_time
>
= #{flowEntityCoreDto.startTime} and trigger_time
<
= #{flowEntityCoreDto.endTime}
</foreach>
</foreach>
and workspace_id = #{flowStatusCoreDtos.workspaceId}
and workspace_id = #{flowStatusCoreDtos.workspaceId}
</if>
</if>
...
...
byit-myth-core/myth-dto-core/src/main/java/com/byit/dto/api/JavaCallbackLogDto.java
View file @
891fc8b5
...
@@ -20,4 +20,6 @@ public class JavaCallbackLogDto implements Serializable {
...
@@ -20,4 +20,6 @@ public class JavaCallbackLogDto implements Serializable {
private
String
logId
;
private
String
logId
;
private
ReturnResult
returnResult
;
private
ReturnResult
returnResult
;
private
String
hasAllReturnOne
;
}
}
byit-myth-core/myth-dto-core/src/main/java/com/byit/dto/plugin/JobStatusDto.java
View file @
891fc8b5
...
@@ -29,4 +29,9 @@ public class JobStatusDto implements Serializable {
...
@@ -29,4 +29,9 @@ public class JobStatusDto implements Serializable {
* 调度类型
* 调度类型
*/
*/
private
ScheduleTypeEnum
scheduleType
;
private
ScheduleTypeEnum
scheduleType
;
/**
* 是否查询全部的标记
*/
private
String
hasMark
;
}
}
byit-myth-core/myth-dto-core/src/main/java/com/byit/dto/plugin/JobStatusResultDto.java
View file @
891fc8b5
...
@@ -38,4 +38,9 @@ public class JobStatusResultDto implements Serializable {
...
@@ -38,4 +38,9 @@ public class JobStatusResultDto implements Serializable {
*/
*/
private
boolean
runIng
;
private
boolean
runIng
;
/**
* 是否查询全部
*/
private
String
hasReturnAllOneMark
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment