Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
cocktail-party-server
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
cocktail-party
cocktail-party-server
Commits
b616a2f2
提交
b616a2f2
authored
7月 15, 2021
作者:
RuoYi
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
定时任务新增更多操作
上级
60abdf1d
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
64 行增加
和
10 行删除
+64
-10
index.vue
ruoyi-ui/src/views/monitor/job/index.vue
+40
-10
log.vue
ruoyi-ui/src/views/monitor/job/log.vue
+24
-0
没有找到文件。
ruoyi-ui/src/views/monitor/job/index.vue
浏览文件 @
b616a2f2
...
@@ -115,17 +115,30 @@
...
@@ -115,17 +115,30 @@
<el-button
<el-button
size=
"mini"
size=
"mini"
type=
"text"
type=
"text"
icon=
"el-icon-
caret-righ
t"
icon=
"el-icon-
edi
t"
@
click=
"handle
Run
(scope.row)"
@
click=
"handle
Update
(scope.row)"
v-hasPermi=
"['monitor:job:
changeStatus
']"
v-hasPermi=
"['monitor:job:
edit
']"
>
执行一次
</el-button>
>
修改
</el-button>
<el-button
<el-button
size=
"mini"
size=
"mini"
type=
"text"
type=
"text"
icon=
"el-icon-view"
icon=
"el-icon-delete"
@
click=
"handleView(scope.row)"
@
click=
"handleDelete(scope.row)"
v-hasPermi=
"['monitor:job:query']"
v-hasPermi=
"['monitor:job:remove']"
>
详细
</el-button>
>
删除
</el-button>
<el-dropdown
size=
"mini"
@
command=
"(command) => handleCommand(command, scope.row)"
>
<span
class=
"el-dropdown-link"
>
<i
class=
"el-icon-d-arrow-right el-icon--right"
></i>
更多
</span>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item
command=
"handleRun"
icon=
"el-icon-caret-right"
v-hasPermi=
"['monitor:job:changeStatus']"
>
执行一次
</el-dropdown-item>
<el-dropdown-item
command=
"handleView"
icon=
"el-icon-view"
v-hasPermi=
"['monitor:job:query']"
>
任务详细
</el-dropdown-item>
<el-dropdown-item
command=
"handleJobLog"
icon=
"el-icon-s-operation"
v-hasPermi=
"['monitor:job:query']"
>
调度日志
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
</el-table>
</el-table>
...
@@ -385,6 +398,22 @@ export default {
...
@@ -385,6 +398,22 @@ export default {
this
.
single
=
selection
.
length
!=
1
;
this
.
single
=
selection
.
length
!=
1
;
this
.
multiple
=
!
selection
.
length
;
this
.
multiple
=
!
selection
.
length
;
},
},
// 更多操作触发
handleCommand
(
command
,
row
)
{
switch
(
command
)
{
case
"handleRun"
:
this
.
handleRun
(
row
);
break
;
case
"handleView"
:
this
.
handleView
(
row
);
break
;
case
"handleJobLog"
:
this
.
handleJobLog
(
row
);
break
;
default
:
break
;
}
},
// 任务状态修改
// 任务状态修改
handleStatusChange
(
row
)
{
handleStatusChange
(
row
)
{
let
text
=
row
.
status
===
"0"
?
"启用"
:
"停用"
;
let
text
=
row
.
status
===
"0"
?
"启用"
:
"停用"
;
...
@@ -420,8 +449,9 @@ export default {
...
@@ -420,8 +449,9 @@ export default {
});
});
},
},
/** 任务日志列表查询 */
/** 任务日志列表查询 */
handleJobLog
()
{
handleJobLog
(
row
)
{
this
.
$router
.
push
(
"/job/log"
);
const
jobId
=
row
.
jobId
||
0
;
this
.
$router
.
push
({
path
:
'/job/log'
,
query
:
{
jobId
:
jobId
}
})
},
},
/** 新增按钮操作 */
/** 新增按钮操作 */
handleAdd
()
{
handleAdd
()
{
...
...
ruoyi-ui/src/views/monitor/job/log.vue
浏览文件 @
b616a2f2
...
@@ -94,6 +94,15 @@
...
@@ -94,6 +94,15 @@
v-hasPermi=
"['monitor:job:export']"
v-hasPermi=
"['monitor:job:export']"
>
导出
</el-button>
>
导出
</el-button>
</el-col>
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"warning"
plain
icon=
"el-icon-close"
size=
"mini"
@
click=
"handleClose"
>
关闭
</el-button>
</el-col>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
</el-row>
...
@@ -168,6 +177,7 @@
...
@@ -168,6 +177,7 @@
</template>
</template>
<
script
>
<
script
>
import
{
getJob
}
from
"@/api/monitor/job"
;
import
{
listJobLog
,
delJobLog
,
exportJobLog
,
cleanJobLog
}
from
"@/api/monitor/jobLog"
;
import
{
listJobLog
,
delJobLog
,
exportJobLog
,
cleanJobLog
}
from
"@/api/monitor/jobLog"
;
export
default
{
export
default
{
...
@@ -209,7 +219,16 @@ export default {
...
@@ -209,7 +219,16 @@ export default {
};
};
},
},
created
()
{
created
()
{
const
jobId
=
this
.
$route
.
query
.
jobId
;
if
(
jobId
!==
undefined
&&
jobId
!=
0
)
{
getJob
(
jobId
).
then
(
response
=>
{
this
.
queryParams
.
jobName
=
response
.
data
.
jobName
;
this
.
queryParams
.
jobGroup
=
response
.
data
.
jobGroup
;
this
.
getList
();
});
}
else
{
this
.
getList
();
this
.
getList
();
}
this
.
getDicts
(
"sys_job_status"
).
then
(
response
=>
{
this
.
getDicts
(
"sys_job_status"
).
then
(
response
=>
{
this
.
statusOptions
=
response
.
data
;
this
.
statusOptions
=
response
.
data
;
});
});
...
@@ -236,6 +255,11 @@ export default {
...
@@ -236,6 +255,11 @@ export default {
jobGroupFormat
(
row
,
column
)
{
jobGroupFormat
(
row
,
column
)
{
return
this
.
selectDictLabel
(
this
.
jobGroupOptions
,
row
.
jobGroup
);
return
this
.
selectDictLabel
(
this
.
jobGroupOptions
,
row
.
jobGroup
);
},
},
// 返回按钮
handleClose
()
{
this
.
$store
.
dispatch
(
"tagsView/delView"
,
this
.
$route
);
this
.
$router
.
push
({
path
:
"/monitor/job"
});
},
/** 搜索按钮操作 */
/** 搜索按钮操作 */
handleQuery
()
{
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
;
this
.
queryParams
.
pageNum
=
1
;
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论