disable stop-testplan button when test plan completed
This commit is contained in:
parent
25c9af9af1
commit
f030705b35
|
@ -28,6 +28,11 @@ $(function() {
|
|||
chartSelector.initChart();
|
||||
graphButtonListener(chartSelector);
|
||||
UrlContentTypeDistribution("pie-chart", testPlanRunId);
|
||||
|
||||
if(testPlan.currentStatus == "Complete"){
|
||||
$("#stop-testplan").attr('disabled', true);
|
||||
}else{
|
||||
$("#stop-testplan").attr('disabled', false);
|
||||
$("#stop-testplan").click(function() {
|
||||
if ($("#status").attr("status") == "InRunning") {
|
||||
$.post("stop/" + testPlanRunId, {}, function(data) {
|
||||
|
@ -35,6 +40,7 @@ $(function() {
|
|||
$('#status').attr("status", "Complete");
|
||||
var testStatus = testStatusMap("Complete");
|
||||
$('#status').html("<h4>" + testStatus + '</h4>');
|
||||
$("#stop-testplan").attr('disabled', true);
|
||||
} else {
|
||||
information($.i18n("stopTestPlan_fail"));
|
||||
}
|
||||
|
@ -48,6 +54,7 @@ $(function() {
|
|||
}
|
||||
|
||||
});
|
||||
}
|
||||
});
|
||||
function getTestInfo(testPlanId) {
|
||||
var testPlan;
|
||||
|
|
Loading…
Reference in New Issue