From 856ff2fa8e9b103ee4033c8ceec3e80af87009bb Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Fri, 11 Jan 2019 16:48:54 +0100 Subject: [serversetup-bwlp] Decouple location assigning from menu editing --- .../templates/menu-assign-location.html | 69 ++++++++++++++++++++++ .../serversetup-bwlp/templates/menu-edit.html | 51 +++------------- 2 files changed, 76 insertions(+), 44 deletions(-) create mode 100644 modules-available/serversetup-bwlp/templates/menu-assign-location.html (limited to 'modules-available/serversetup-bwlp/templates') diff --git a/modules-available/serversetup-bwlp/templates/menu-assign-location.html b/modules-available/serversetup-bwlp/templates/menu-assign-location.html new file mode 100644 index 00000000..077d137e --- /dev/null +++ b/modules-available/serversetup-bwlp/templates/menu-assign-location.html @@ -0,0 +1,69 @@ +

{{lang_assignMenuToLocation}}

+

{{locationName}}

+ +
+ + + + + + + + + + + + + + + + + + + {{#list}} + + + + + + {{/list}} + +
{{lang_menuTitle}}{{lang_menuEntryOverride}}
+
+ + +
+
+ {{lang_useDefaultMenu}} +
+
+ + +
+
+ {{title}} + + +
+ +
+ +
+ +
+ +
+ + \ No newline at end of file diff --git a/modules-available/serversetup-bwlp/templates/menu-edit.html b/modules-available/serversetup-bwlp/templates/menu-edit.html index 2141103f..21c6a30e 100644 --- a/modules-available/serversetup-bwlp/templates/menu-edit.html +++ b/modules-available/serversetup-bwlp/templates/menu-edit.html @@ -36,33 +36,18 @@ -
-
- -
-
- - {{#globalMenuWarning}} - - {{/globalMenuWarning}} -
-
- - - + + + - - - - + + + + @@ -289,28 +274,6 @@ var spacerText = "{{lang_spacer}}"; document.addEventListener("DOMContentLoaded", function() { - var locationSelect = $('#panel-locations'); - locationSelect.multiselect({numberDisplayed: 1}); - var globalMenuWarning = $('#global-menu-warning'); - if (globalMenuWarning.length) { - var saveButton = $('#save-button'); - if (locationSelect.val() !== null) { - saveButton.prop('disabled', false); - globalMenuWarning.hide(); - } else { - saveButton.prop('disabled', true); - globalMenuWarning.show(); - } - locationSelect.change(function () { - if ($(this).val() !== null) { - saveButton.prop('disabled', false); - globalMenuWarning.hide(); - } else { - saveButton.prop('disabled', true); - globalMenuWarning.show(); - } - }); - } function reassignSortValues() { var startValue = 1; -- cgit v1.2.3-55-g7522
{{lang_entryId}}{{lang_entryId}} {{lang_title}}{{lang_hotkey}}{{lang_password}}{{lang_hotkey}}{{lang_password}}