diff options
author | Simon Rettberg | 2021-03-03 14:30:59 +0100 |
---|---|---|
committer | Simon Rettberg | 2021-03-03 14:30:59 +0100 |
commit | 6455db73f499b69e0243eecf872d716f507cbc26 (patch) | |
tree | 4d9816e0baa0c535347825fe2eee13c66f08f019 /modules-available/serversetup-bwlp-ipxe/page.inc.php | |
parent | [rebootcontrol] Increase subnet delete timeout (diff) | |
download | slx-admin-6455db73f499b69e0243eecf872d716f507cbc26.tar.gz slx-admin-6455db73f499b69e0243eecf872d716f507cbc26.tar.xz slx-admin-6455db73f499b69e0243eecf872d716f507cbc26.zip |
[serversetup-bwlp-ipxe] Location-override: Show default, label for=""
Make label clickable by adding id/for pairs.
Show menu default entry below menu name.
Diffstat (limited to 'modules-available/serversetup-bwlp-ipxe/page.inc.php')
-rw-r--r-- | modules-available/serversetup-bwlp-ipxe/page.inc.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules-available/serversetup-bwlp-ipxe/page.inc.php b/modules-available/serversetup-bwlp-ipxe/page.inc.php index b5a70c25..e31814d1 100644 --- a/modules-available/serversetup-bwlp-ipxe/page.inc.php +++ b/modules-available/serversetup-bwlp-ipxe/page.inc.php @@ -915,7 +915,8 @@ class Page_ServerSetup extends Page ]; $menu = IPxeMenu::forLocation($loc['parentlocationid']); $data['defaultMenu'] = $menu; - $res = Database::simpleQuery('SELECT m.menuid, m.title, ml.locationid, ml.defaultentryid, GROUP_CONCAT(me.menuentryid) AS entries + $res = Database::simpleQuery('SELECT m.defaultentryid AS menu_default, m.menuid, m.title, ml.locationid, + ml.defaultentryid, GROUP_CONCAT(me.menuentryid) AS entries FROM serversetup_menu m LEFT JOIN serversetup_menu_location ml ON (m.menuid = ml.menuid AND ml.locationid = :locationid) INNER JOIN serversetup_menuentry me ON (m.menuid = me.menuid AND me.entryid IS NOT NULL) @@ -925,6 +926,7 @@ class Page_ServerSetup extends Page $hasDefault = false; while ($row = $res->fetch(PDO::FETCH_ASSOC)) { $eids = explode(',', $row['entries']); + $row['default_entry_title'] = $menuEntries[$row['menu_default']] ?? ''; $row['entries'] = []; foreach ($eids as $eid) { $row['entries'][] = [ |