move exe button to edit citask page, add request success tips
This commit is contained in:
@@ -0,0 +1 @@
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
$(function()
|
||||
{
|
||||
|
||||
})
|
||||
@@ -3,6 +3,20 @@ $(function()
|
||||
triggerTypeChanged(triggerType);
|
||||
});
|
||||
|
||||
function exeCitask(id) {
|
||||
var link = createLink('ci', 'exeCitask', 'id=' + id);
|
||||
console.log(link);
|
||||
$.ajax({
|
||||
type:"POST",
|
||||
url: link,
|
||||
data: {},
|
||||
datatype: "json",
|
||||
success:function(str){
|
||||
$('.exe-citask-button').tooltip('show', '发送执行请求成功!');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function triggerTypeChanged(type) {
|
||||
if(type == 'tag') {
|
||||
$('.tag-fields').removeClass('hidden');
|
||||
|
||||
@@ -59,6 +59,7 @@ $lang->citask->common = '构建任务';
|
||||
$lang->citask->browse = '浏览构建任务';
|
||||
$lang->citask->create = '添加构建任务';
|
||||
$lang->citask->edit = '编辑构建任务';
|
||||
$lang->citask->exeNow = '立即执行';
|
||||
$lang->citask->delete = '删除构建任务';
|
||||
$lang->citask->confirmDelete = '确认删除该构建任务吗?';
|
||||
|
||||
|
||||
@@ -54,7 +54,6 @@
|
||||
|
||||
<td class='c-actions text-right'>
|
||||
<?php
|
||||
common::printIcon('ci', 'exeCitask', "citaskID=$id", '', 'list', 'play');
|
||||
common::printIcon('ci', 'editCitask', "citaskID=$id", '', 'list', 'edit');
|
||||
|
||||
if (common::hasPriv('ci', 'deleteCitask')) {
|
||||
|
||||
@@ -106,9 +106,11 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<th></th>
|
||||
<td class='text-center form-actions'>
|
||||
<td colspan="2" class='text-center form-actions'>
|
||||
<?php echo html::submitButton(); ?>
|
||||
<?php echo html::backButton(); ?>
|
||||
|
||||
<?php echo html::commonButton($lang->citask->exeNow, "onclick=exeCitask($citask->id) data-tip-class='tooltip-success'", "btn btn-info exe-citask-button"); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user