Skip to content

Commit

Permalink
QUWITHDEP queue entries can now be edited #2555
Browse files Browse the repository at this point in the history
  • Loading branch information
vertigo17 committed Dec 7, 2024
1 parent 4825800 commit 18fa0f2
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ <h4 class="modal-title" id="editTestCaseModalLabel" name="editTestCaseField">Edi

<div class="row">
<div class="form-group col-sm-12">
<label name="lbl_testcasesDependencyList">This test case must be execute after</label>
<label name="lbl_testcasesDependencyList">Test case will be executed after those following dependencies :</label>
<div>
<div class="dataTables_scroll">
<div class="dataTables_scrollHead ui-state-default" style="overflow: hidden; border: 0px; width: 100%;">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -346,8 +346,10 @@ function feedExecutionQueueModalData(exeQ, modalId, mode, hasPermissionsUpdate)

var formEdit = $('#' + modalId);
var doc = new Doc();
var isEditable = (((hasPermissionsUpdate) && (mode === "EDIT") && ((exeQ.state === "WAITING") || (exeQ.state === "QUEUED") || (exeQ.state === "ERROR") || (exeQ.state === "CANCELLED")))
|| (mode === "DUPLICATE"));
var isEditable = (
((hasPermissionsUpdate) && (mode === "EDIT") && ((exeQ.state === "WAITING") || (exeQ.state === "QUEUED") || (exeQ.state === "QUWITHDEP") || (exeQ.state === "ERROR") || (exeQ.state === "CANCELLED")))
|| (mode === "DUPLICATE")
);

formEdit.find("#test").empty();
formEdit.find("#testCase").empty();
Expand Down Expand Up @@ -625,11 +627,24 @@ function appendDepRow(dep, targetTableBody) {
exeButton.attr("disabled", true);
}
exeButtonA.append(exeButton);

var queButton = $("<button>").attr("type", "button").addClass("btn btn-sm").append($("<span>").addClass("glyphicon glyphicon-new-window"));
var queButtonA = $("<a>");
if (dep.exeId > 0) {
queButtonA.attr("href", "./TestCaseExecution.jsp?executionQueueId=" + dep.queueId);
} else {
queButton.attr("disabled", true);
}
queButtonA.append(queButton);

//onclick=\"window.open=('this.href'); target='_blank';stopPropagation(event)\"
var exeIdInput = $("<div>").addClass("input-group")
.append($("<input readonly>").addClass("form-control input-sm").val(dep.exeId))
.append($("<span>").addClass("input-group-btn").append(exeButtonA));
var queueIdInput = $("<input readonly>").addClass("form-control input-sm").val(dep.queueId);
var queueIdInput = $("<div>").addClass("input-group")
.append($("<input readonly>").addClass("form-control input-sm").val(dep.queueId))
.append($("<span>").addClass("input-group-btn").append(queButtonA));
// var queueIdInput = $("<input readonly>").addClass("form-control input-sm").val(dep.queueId);
var table = $("#" + targetTableBody);

var row = $("<tr></tr>");
Expand Down

0 comments on commit 18fa0f2

Please sign in to comment.