|
|
@ -124,8 +124,12 @@
|
|
|
|
align: 'center',
|
|
|
|
align: 'center',
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
formatter: function(value, row, index) {
|
|
|
|
var actions = [];
|
|
|
|
var actions = [];
|
|
|
|
actions.push('<a class="btn btn-primary btn-xs ' + statusFlag + '" href="javascript:void(0)" onclick="run(\'' + row.jobId + '\', \'' + row.jobGroup + '\')"><i class="fa fa-play-circle-o"></i> 执行一次</a> ');
|
|
|
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.jobId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
|
|
|
actions.push('<a class="btn btn-warning btn-xs ' + detailFlag + '" href="javascript:void(0)" onclick="$.operate.detail(\'' + row.jobId + '\')"><i class="fa fa-search"></i>详细</a> ');
|
|
|
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.jobId + '\')"><i class="fa fa-remove"></i>删除</a> ');
|
|
|
|
|
|
|
|
var more = [];
|
|
|
|
|
|
|
|
more.push("<a class='btn btn-default btn-xs " + statusFlag + "' href='javascript:void(0)' onclick='run(" + row.jobId + ")'><i class='fa fa-play-circle-o'></i> 执行一次</a> ");
|
|
|
|
|
|
|
|
more.push("<a class='btn btn-default btn-xs " + detailFlag + "' href='javascript:void(0)' onclick='$.operate.detail(" + row.jobId + ")'><i class='fa fa-search'></i>任务详细</a> ");
|
|
|
|
|
|
|
|
actions.push('<a class="btn btn-info btn-xs" data-toggle="popover" data-content="' + more.join('') + '"><i class="fa fa-chevron-circle-right"></i>更多操作</a>');
|
|
|
|
return actions.join('');
|
|
|
|
return actions.join('');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}]
|
|
|
|
}]
|
|
|
@ -143,9 +147,9 @@
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/* 立即执行一次 */
|
|
|
|
/* 立即执行一次 */
|
|
|
|
function run(jobId, jobGroup) {
|
|
|
|
function run(jobId) {
|
|
|
|
$.modal.confirm("确认要立即执行一次任务吗?", function() {
|
|
|
|
$.modal.confirm("确认要立即执行一次任务吗?", function() {
|
|
|
|
$.operate.post(prefix + "/run", { "jobId": jobId, "jobGroup": jobGroup});
|
|
|
|
$.operate.post(prefix + "/run", { "jobId": jobId});
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|