mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-06-12 10:00:56 +08:00
优化定时任务手工测试
This commit is contained in:
parent
d0d830b0ff
commit
afc34da559
@ -109,6 +109,11 @@
|
|||||||
停止
|
停止
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="btn-group">
|
||||||
|
<button class="btn-white btn btn-xs" v-on:click="_openRunJob(job)">
|
||||||
|
测试
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
<div class="btn-group">
|
<div class="btn-group">
|
||||||
<button class="btn-white btn btn-xs" v-on:click="_openEditJobModel(job)">
|
<button class="btn-white btn btn-xs" v-on:click="_openEditJobModel(job)">
|
||||||
修改
|
修改
|
||||||
|
|||||||
@ -76,7 +76,7 @@
|
|||||||
taskId: _job.taskId
|
taskId: _job.taskId
|
||||||
};
|
};
|
||||||
vc.http.apiPost(
|
vc.http.apiPost(
|
||||||
'task.startTask',
|
'/task.startTask',
|
||||||
JSON.stringify(param), {
|
JSON.stringify(param), {
|
||||||
emulateJSON: true
|
emulateJSON: true
|
||||||
},
|
},
|
||||||
@ -130,7 +130,32 @@
|
|||||||
vc.component.jobManageInfo.conditions.taskName = "";
|
vc.component.jobManageInfo.conditions.taskName = "";
|
||||||
vc.component.jobManageInfo.conditions.templateName = "";
|
vc.component.jobManageInfo.conditions.templateName = "";
|
||||||
vc.component._listJobs(DEFAULT_PAGE, DEFAULT_ROWS);
|
vc.component._listJobs(DEFAULT_PAGE, DEFAULT_ROWS);
|
||||||
}
|
},
|
||||||
|
_openRunJob: function (_job) {
|
||||||
|
let param = {
|
||||||
|
taskId: _job.taskId
|
||||||
|
};
|
||||||
|
vc.http.apiPost(
|
||||||
|
'/job.runJob',
|
||||||
|
JSON.stringify(param), {
|
||||||
|
emulateJSON: true
|
||||||
|
},
|
||||||
|
function (json, res) {
|
||||||
|
let _json = JSON.parse(json);
|
||||||
|
if (_json.code == 0) {
|
||||||
|
//关闭model
|
||||||
|
vc.component._listJobs(DEFAULT_PAGE, DEFAULT_ROWS);
|
||||||
|
vc.toast(_json.msg);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
vc.toast(_json.msg);
|
||||||
|
|
||||||
|
},
|
||||||
|
function (errInfo, error) {
|
||||||
|
console.log('请求失败处理');
|
||||||
|
vc.toast(errInfo);
|
||||||
|
});
|
||||||
|
},
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
})(window.vc);
|
})(window.vc);
|
||||||
Loading…
Reference in New Issue
Block a user