summaryrefslogtreecommitdiffstats
path: root/modules-available/runmode
diff options
context:
space:
mode:
authorSimon Rettberg2017-11-28 16:41:33 +0100
committerSimon Rettberg2017-11-28 16:41:33 +0100
commit23d8c6fc0c3b031aa081ee1a245f9b0792514fd3 (patch)
tree59ce05e8add76d7b63213a0fa447a42565ea2e3d /modules-available/runmode
parent[dnbd3] Disable SLX_SYSTEM_STANDBY_TIMEOUT (diff)
downloadslx-admin-23d8c6fc0c3b031aa081ee1a245f9b0792514fd3.tar.gz
slx-admin-23d8c6fc0c3b031aa081ee1a245f9b0792514fd3.tar.xz
slx-admin-23d8c6fc0c3b031aa081ee1a245f9b0792514fd3.zip
[statistics] Introduce state column to get rid of complicated state determination
This also adds support for the STANDBY state
Diffstat (limited to 'modules-available/runmode')
-rw-r--r--modules-available/runmode/templates/machine-selector.html15
1 files changed, 13 insertions, 2 deletions
diff --git a/modules-available/runmode/templates/machine-selector.html b/modules-available/runmode/templates/machine-selector.html
index d3ff7378..7f37f5a2 100644
--- a/modules-available/runmode/templates/machine-selector.html
+++ b/modules-available/runmode/templates/machine-selector.html
@@ -108,11 +108,22 @@ function renderMachineSelected(item, escape) {
}
document.addEventListener('DOMContentLoaded', function () {
+ Selectize.define("no_bs", function (options) {
+ var original = this.deleteSelection;
+ this.deleteSelection = (function() {
+ return function (e) {
+ if (!e || e.keyCode !== 8) {
+ return original.apply(this, arguments);
+ }
+ return false;
+ };
+ })();
+ });
var old = {{{machines}}} || [];
var $box = $('#machine-sel').selectize({
options: old,
items: old.map(function(x) { return x.machineuuid; }),
- plugins: ["remove_button"],
+ plugins: ["remove_button", "no_bs"],
valueField: 'machineuuid',
searchField: "combined",
openOnFocus: false,
@@ -121,7 +132,7 @@ document.addEventListener('DOMContentLoaded', function () {
load: loadMachines,
maxItems: null,
sortField: 'hostname',
- sortDirection: 'asc'
+ sortDirection: 'asc',
});
});