Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
dataease
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
zhu
dataease
Commits
8d144a48
Unverified
提交
8d144a48
authored
7月 13, 2021
作者:
taojinlong
提交者:
GitHub
7月 13, 2021
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #231 from dataease/pr@dev@fix-task
fix: 执行记录状态修改;执行记录显示错误;简单执行增加描述
上级
bfdb77fa
e42b8b73
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
48 行增加
和
17 行删除
+48
-17
GridExample.java
...n/java/io/dataease/base/mapper/ext/query/GridExample.java
+10
-1
DataSetTableTaskLogService.java
.../dataease/service/dataset/DataSetTableTaskLogService.java
+13
-1
dataset.js
frontend/src/api/dataset/dataset.js
+2
-2
en.js
frontend/src/lang/en.js
+3
-0
tw.js
frontend/src/lang/tw.js
+5
-2
zh.js
frontend/src/lang/zh.js
+5
-2
DatasetTaskList.vue
frontend/src/views/system/task/DatasetTaskList.vue
+9
-8
TaskRecord.vue
frontend/src/views/system/task/TaskRecord.vue
+1
-1
没有找到文件。
backend/src/main/java/io/dataease/base/mapper/ext/query/GridExample.java
浏览文件 @
8d144a48
...
...
@@ -103,6 +103,10 @@ public class GridExample {
criteria
.
add
(
new
Criterion
(
condition
));
}
protected
void
addNotNullCriterion
(
String
condition
)
{
criteria
.
add
(
new
Criterion
(
condition
,
null
));
}
protected
void
addCriterion
(
String
condition
,
Object
value
,
String
property
)
{
if
(
value
==
null
)
{
throw
new
RuntimeException
(
"Value for "
+
property
+
" cannot be null"
);
...
...
@@ -164,6 +168,9 @@ public class GridExample {
case
"le"
:
addCriterion
(
field
+
" <= "
,
value
,
field
);
break
;
case
"not null"
:
addNotNullCriterion
(
field
+
" is not null "
);
break
;
}
return
(
Criteria
)
this
;
}
...
...
@@ -242,7 +249,9 @@ public class GridExample {
this
.
condition
=
condition
;
this
.
value
=
value
;
this
.
typeHandler
=
typeHandler
;
if
(
value
instanceof
List
<?>)
{
if
(
value
==
null
){
this
.
noValue
=
true
;
}
else
if
(
value
instanceof
List
<?>)
{
this
.
listValue
=
true
;
}
else
{
this
.
singleValue
=
true
;
...
...
backend/src/main/java/io/dataease/service/dataset/DataSetTableTaskLogService.java
浏览文件 @
8d144a48
package
io
.
dataease
.
service
.
dataset
;
import
com.google.gson.Gson
;
import
io.dataease.base.domain.DatasetTableTask
;
import
io.dataease.base.domain.DatasetTableTaskLog
;
import
io.dataease.base.domain.DatasetTableTaskLogExample
;
...
...
@@ -8,6 +9,7 @@ import io.dataease.base.mapper.DatasetTableTaskMapper;
import
io.dataease.base.mapper.ext.ExtDataSetTaskMapper
;
import
io.dataease.base.mapper.ext.query.GridExample
;
import
io.dataease.controller.sys.base.BaseGridRequest
;
import
io.dataease.controller.sys.base.ConditionEntity
;
import
io.dataease.dto.dataset.DataSetTaskDTO
;
import
io.dataease.dto.dataset.DataSetTaskLogDTO
;
import
org.apache.commons.collections4.CollectionUtils
;
...
...
@@ -15,6 +17,7 @@ import org.apache.commons.lang3.StringUtils;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.UUID
;
...
...
@@ -45,6 +48,15 @@ public class DataSetTableTaskLogService {
}
public
List
<
DataSetTaskLogDTO
>
list
(
BaseGridRequest
request
)
{
ConditionEntity
entity
=
new
ConditionEntity
();
entity
.
setField
(
"task_id"
);
entity
.
setOperator
(
"not null"
);
List
<
ConditionEntity
>
conditionEntities
=
request
.
getConditions
();
if
(
CollectionUtils
.
isEmpty
(
conditionEntities
)){
conditionEntities
=
new
ArrayList
<>();
}
conditionEntities
.
add
(
entity
);
request
.
setConditions
(
conditionEntities
);
GridExample
gridExample
=
request
.
convertExample
();
return
extDataSetTaskMapper
.
list
(
gridExample
);
}
...
...
@@ -78,7 +90,7 @@ public class DataSetTableTaskLogService {
if
(
StringUtils
.
isNotEmpty
(
dataSetTaskDTO
.
getId
())){
criteria
.
andTaskIdEqualTo
(
dataSetTaskDTO
.
getId
());
}
example
.
setOrderByClause
(
"create_time desc
limit 1
"
);
example
.
setOrderByClause
(
"create_time desc"
);
List
<
DatasetTableTaskLog
>
datasetTableTaskLogs
=
datasetTableTaskLogMapper
.
selectByExampleWithBLOBs
(
example
);
if
(
CollectionUtils
.
isNotEmpty
(
datasetTableTaskLogs
)){
dataSetTaskDTO
.
setLastExecStatus
(
datasetTableTaskLogs
.
get
(
0
).
getStatus
());
...
...
frontend/src/api/dataset/dataset.js
浏览文件 @
8d144a48
...
...
@@ -136,12 +136,12 @@ export function taskList(spage, size, data) {
})
}
export
function
datasetTaskList
(
page
,
size
,
data
)
{
export
function
datasetTaskList
(
page
,
size
,
data
,
loading
)
{
return
request
({
url
:
'/dataset/task/pageList/'
+
page
+
'/'
+
size
,
method
:
'post'
,
data
,
loading
:
true
loading
:
loading
})
}
...
...
frontend/src/lang/en.js
浏览文件 @
8d144a48
...
...
@@ -1200,6 +1200,9 @@ export default {
minute
:
'Minute'
,
hour
:
'Hour'
,
day
:
'Day'
,
minute_default
:
'Minutes (execution time: 0 seconds)'
,
hour_default
:
'Hours (execution time: 0 minutes 0 seconds)'
,
day_default
:
'Day (execution time: 0:00:00)'
,
month
:
'Month'
,
week
:
'Week'
,
year
:
'Year'
,
...
...
frontend/src/lang/tw.js
浏览文件 @
8d144a48
...
...
@@ -856,8 +856,8 @@ export default {
start_time
:
'開始時間'
,
end_time
:
'結束時間'
,
status
:
'狀態'
,
error
:
'
錯誤
'
,
completed
:
'
完成
'
,
error
:
'
失敗
'
,
completed
:
'
成功
'
,
underway
:
'執行中'
,
task_update
:
'更新設置'
,
update_type
:
'更新方式'
,
...
...
@@ -1200,6 +1200,9 @@ export default {
minute
:
'分'
,
hour
:
'時'
,
day
:
'日'
,
minute_default
:
'分 (執行時間:0秒)'
,
hour_default
:
'時 (執行時間:0分0秒)'
,
day_default
:
'日 (執行時間:0時0分0秒)'
,
month
:
'月'
,
week
:
'周'
,
year
:
'年'
,
...
...
frontend/src/lang/zh.js
浏览文件 @
8d144a48
...
...
@@ -856,8 +856,8 @@ export default {
start_time
:
'开始时间'
,
end_time
:
'结束时间'
,
status
:
'状态'
,
error
:
'
错误
'
,
completed
:
'
完成
'
,
error
:
'
失败
'
,
completed
:
'
成功
'
,
underway
:
'执行中'
,
task_update
:
'更新设置'
,
update_type
:
'更新方式'
,
...
...
@@ -1202,6 +1202,9 @@ export default {
minute
:
'分'
,
hour
:
'时'
,
day
:
'日'
,
minute_default
:
'分 (执行时间:0秒)'
,
hour_default
:
'时 (执行时间:0分0秒)'
,
day_default
:
'日 (执行时间:0时0分0秒)'
,
month
:
'月'
,
week
:
'周'
,
year
:
'年'
,
...
...
frontend/src/views/system/task/DatasetTaskList.vue
浏览文件 @
8d144a48
...
...
@@ -99,12 +99,13 @@
<el-form-item
class=
"form-item"
>
<el-select
v-model=
"taskForm.extraData.simple_cron_type"
filterable
size=
"mini"
@
change=
"onSimpleCronChange()"
>
<el-option
:label=
"$t('cron.minute')"
value=
"minute"
/>
<el-option
:label=
"$t('cron.hour')"
value=
"hour"
/>
<el-option
:label=
"$t('cron.day')"
value=
"day"
/>
<el-option
:label=
"$t('cron.minute
_default
')"
value=
"minute"
/>
<el-option
:label=
"$t('cron.hour
_default
')"
value=
"hour"
/>
<el-option
:label=
"$t('cron.day
_default
')"
value=
"day"
/>
</el-select>
</el-form-item>
<el-form-item
class=
"form-item"
:label=
"$t('cron.every_exec')"
>
<el-form-item
class=
"form-item"
:label=
"$t('cron.every_exec')"
>
</el-form-item>
</el-form>
</el-form-item>
...
...
@@ -289,7 +290,7 @@ export default {
created
()
{
this
.
search
()
this
.
timer
=
setInterval
(()
=>
{
this
.
search
()
this
.
search
(
this
.
last_condition
,
false
)
},
5000
)
},
beforeDestroy
()
{
...
...
@@ -314,14 +315,14 @@ export default {
},
select
(
selection
)
{
},
search
(
condition
)
{
search
(
condition
,
showLoading
=
true
)
{
this
.
last_condition
=
condition
condition
=
formatQuickCondition
(
condition
,
'dataset_table_task.name'
)
const
temp
=
formatCondition
(
condition
)
const
param
=
temp
||
{}
param
[
'orders'
]
=
formatOrders
(
this
.
orderConditions
)
const
{
currentPage
,
pageSize
}
=
this
.
paginationConfig
datasetTaskList
(
currentPage
,
pageSize
,
param
).
then
(
response
=>
{
datasetTaskList
(
currentPage
,
pageSize
,
param
,
showLoading
).
then
(
response
=>
{
this
.
data
=
response
.
data
.
listObject
this
.
data
.
forEach
(
item
=>
{
this
.
taskStatus
(
item
)
...
...
@@ -330,7 +331,7 @@ export default {
})
},
taskStatus
(
item
)
{
post
(
'/dataset/task/lastExecStatus'
,
item
).
then
(
response
=>
{
post
(
'/dataset/task/lastExecStatus'
,
item
,
false
).
then
(
response
=>
{
if
(
!
item
.
lastExecStatus
)
{
item
.
lastExecStatus
=
response
.
data
.
lastExecStatus
}
...
...
frontend/src/views/system/task/TaskRecord.vue
浏览文件 @
8d144a48
...
...
@@ -106,7 +106,7 @@ export default {
created
()
{
this
.
search
()
this
.
timer
=
setInterval
(()
=>
{
this
.
search
()
this
.
search
(
this
.
last_condition
,
false
)
},
5000
)
},
computed
:
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论