diff options
Diffstat (limited to 'data/lib/bzpage.js')
-rw-r--r-- | data/lib/bzpage.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/data/lib/bzpage.js b/data/lib/bzpage.js index bd8e6ce..1a3e6b4 100644 --- a/data/lib/bzpage.js +++ b/data/lib/bzpage.js @@ -75,6 +75,7 @@ function centralCommandDispatch (cmdLabel, cmdParams) { console.log("centralCommandDispatch : cmdLabel = " + cmdLabel); switch (cmdLabel) { case "name": + case "position": break; case "resolution": case "product": @@ -248,22 +249,25 @@ function changeAssignee (newAssignee) { function addToCommentsDropdown (cmdObj) { var select = document.getElementById("comment_action"); if (!select) { + config.commandsList = []; document.getElementById("comments").innerHTML += "<div id='make_bugzilla_comment_action'>" + " <label for='comment_action'>Add Comment: </label>" + " <select id='comment_action'>" + " <option value=''>-- Select Comment from List --</option>" + + " </select>" + "</div>"; select = document.getElementById("comment_action"); select.addEventListener("change", function (evt) { var value = select.options[select.selectedIndex].value; - log("value = " + value); - executeCommand(value); + executeCommand(config.commandsList[value]); }, false); } var opt = document.createElement("option"); - opt.value = cmdObj; + var objIdx = config.commandsList.length + 1; + opt.value = objIdx; + config.commandsList[objIdx] = cmdObj; opt.textContent = cmdObj.name; select.appendChild(opt); } @@ -332,7 +336,7 @@ function generateButtons (pkgs, kNodes) { // ========================================================= if (kNodes && window.location.hostname in kNodes) { - var killConf = killNodes[window.location.hostname]; + var killConf = kNodes[window.location.hostname]; killNodes(document, killConf[0], killConf[1]); } |