diff options
author | Simon Rettberg | 2019-03-20 15:35:56 +0100 |
---|---|---|
committer | Simon Rettberg | 2019-03-20 15:35:56 +0100 |
commit | b051fb4dd78482a8d51559df09668ae2bb382113 (patch) | |
tree | d80c7e71cd6eb20def19d5ad76e56becd7415cfb /modules-available/serversetup-bwlp-ipxe/templates | |
parent | [serversetup-bwlp-ipxe] Chainfix: Add netX/ to DHCP opts too (diff) | |
download | slx-admin-b051fb4dd78482a8d51559df09668ae2bb382113.tar.gz slx-admin-b051fb4dd78482a8d51559df09668ae2bb382113.tar.xz slx-admin-b051fb4dd78482a8d51559df09668ae2bb382113.zip |
[serversetup-bwlp-ipxe] Bootentry: add copy button & allow view only
Diffstat (limited to 'modules-available/serversetup-bwlp-ipxe/templates')
-rw-r--r-- | modules-available/serversetup-bwlp-ipxe/templates/bootentry-list.html | 20 | ||||
-rw-r--r-- | modules-available/serversetup-bwlp-ipxe/templates/ipxe-new-boot-entry.html | 32 |
2 files changed, 33 insertions, 19 deletions
diff --git a/modules-available/serversetup-bwlp-ipxe/templates/bootentry-list.html b/modules-available/serversetup-bwlp-ipxe/templates/bootentry-list.html index 8185ad06..edfc0e5f 100644 --- a/modules-available/serversetup-bwlp-ipxe/templates/bootentry-list.html +++ b/modules-available/serversetup-bwlp-ipxe/templates/bootentry-list.html @@ -12,6 +12,7 @@ <th>{{lang_hotkey}}</th> <th class="slx-smallcol">{{lang_refCount}}</th> <th class="slx-smallcol">{{lang_edit}}</th> + {{#allowEdit}}<th class="slx-smallcol">{{lang_copy}}</th>{{/allowEdit}} <th class="slx-smallcol">{{lang_delete}}</th> </tr> </thead> @@ -31,17 +32,24 @@ {{refs}} </td> <td align="center"> - {{#allowEdit}} <a href="?do=serversetup&show=editbootentry&id={{entryid}}" class="btn btn-xs btn-default"> - <span class="glyphicon glyphicon-edit"></span> + <span class="glyphicon glyphicon-{{#allowEdit}}edit{{/allowEdit}}{{^allowEdit}}eye-open{{/allowEdit}}"></span> + </a> + </td> + {{#allowEdit}} + <td align="center"> + <a href="?do=serversetup&show=editbootentry&id={{entryid}}©=true" class="btn btn-xs btn-default"> + <span class="glyphicon glyphicon-duplicate"></span> </a> - {{/allowEdit}} </td> + {{/allowEdit}} <td align="center"> {{#allowEdit}} - <button type="button" class="btn btn-xs btn-danger" data-toggle="modal" data-target="#deleteModal" onclick="deleteBootentry('{{entryid}}', '{{builtin}}')"> - <span class="glyphicon glyphicon-trash"></span> - </button> + {{^builtin}} + <button type="button" class="btn btn-xs btn-danger" data-toggle="modal" data-target="#deleteModal" onclick="deleteBootentry('{{entryid}}')"> + <span class="glyphicon glyphicon-trash"></span> + </button> + {{/builtin}} {{/allowEdit}} </td> </tr> diff --git a/modules-available/serversetup-bwlp-ipxe/templates/ipxe-new-boot-entry.html b/modules-available/serversetup-bwlp-ipxe/templates/ipxe-new-boot-entry.html index a6955642..c04661f2 100644 --- a/modules-available/serversetup-bwlp-ipxe/templates/ipxe-new-boot-entry.html +++ b/modules-available/serversetup-bwlp-ipxe/templates/ipxe-new-boot-entry.html @@ -1,4 +1,9 @@ +{{^oldentryid}} <h2>{{lang_newBootEntryHead}}</h2> +{{/oldentryid}} +{{#oldentryid}} + <h2>{{lang_editBootEntryHead}}</h2> +{{/oldentryid}} {{#builtin}} <div class="alert alert-warning"> @@ -18,11 +23,11 @@ <div class="form-group"> <div class="radio"> - <input class="type-radio" type="radio" name="type" value="exec" id="type-exec" {{exec_checked}}> + <input class="type-radio" type="radio" name="type" value="exec" id="type-exec" {{exec_checked}} {{disabled}}> <label for="type-exec">{{lang_typeExecEntry}}</label> </div> <div class="radio"> - <input class="type-radio" type="radio" name="type" value="script" id="type-script" {{script_checked}}> + <input class="type-radio" type="radio" name="type" value="script" id="type-script" {{script_checked}} {{disabled}}> <label for="type-script">{{lang_typeScriptEntry}}</label> </div> </div> @@ -31,13 +36,14 @@ <label for="input-id"> {{lang_entryId}} {{lang_idFormatHint}} </label> - <input id="input-id" class="form-control" name="newid" value="{{entryid}}" pattern="^[a-z0-9\-_]{1,16}$" minlength="1" maxlength="16" required> + <input id="input-id" class="form-control" name="newid" value="{{entryid}}" pattern="^[a-z0-9\-_]{1,16}$" + minlength="1" maxlength="16" required {{#builtin}}readonly{{/builtin}} {{disabled}}> </div> <div class="form-group"> <label for="input-title"> {{lang_entryTitle}} </label> - <input id="input-title" class="form-control" name="title" value="{{title}}" maxlength="100"> + <input id="input-title" class="form-control" name="title" value="{{title}}" maxlength="100" {{disabled}}> </div> <div class="type-form" id="form-exec"> @@ -45,7 +51,7 @@ <label for="arch-selector"> {{lang_archSelector}} </label> - <select id="arch-selector" class="form-control" name="entry[arch]"> + <select id="arch-selector" class="form-control" name="entry[arch]" {{disabled}}> <option value="agnostic" {{agnostic_selected}}>{{lang_archAgnostic}}</option> <option value="PCBIOS" {{PCBIOS_selected}}>{{lang_biosOnly}}</option> <option value="EFI" {{EFI_selected}}>{{lang_efiOnly}}</option> @@ -62,39 +68,39 @@ <label for="input-ex"> {{lang_imageToLoad}} </label> - <input id="input-ex" class="form-control" name="entry[executable][{{mode}}]" value="{{executable}}"> + <input id="input-ex" class="form-control" name="entry[executable][{{mode}}]" value="{{executable}}" {{disabled}}> </div> <div class="form-group"> <label for="input-rd"> {{lang_initRd}} </label> - <input id="input-rd" class="form-control" name="entry[initRd][{{mode}}]" value="{{initRd}}"> + <input id="input-rd" class="form-control" name="entry[initRd][{{mode}}]" value="{{initRd}}" {{disabled}}> </div> <div class="form-group"> <label for="input-cmd"> {{lang_commandLine}} </label> <input id="input-cmd" class="form-control" name="entry[commandLine][{{mode}}]" - value="{{commandLine}}"> + value="{{commandLine}}" {{disabled}}> </div> <div class="form-group"> <div class="checkbox checkbox-inline"> <input id="exec-replace-{{mode}}" class="form-control" type="checkbox" - name="entry[replace][{{mode}}]" {{replace_checked}}> + name="entry[replace][{{mode}}]" {{replace_checked}} {{disabled}}> <label for="exec-replace-{{mode}}">{{lang_execReplace}}</label> </div> </div> <div class="form-group"> <div class="checkbox checkbox-inline"> <input id="exec-au-{{mode}}" class="form-control" type="checkbox" - name="entry[autoUnload][{{mode}}]" {{autoUnload_checked}}> + name="entry[autoUnload][{{mode}}]" {{autoUnload_checked}} {{disabled}}> <label for="exec-au-{{mode}}">{{lang_execAutoUnload}}</label> </div> </div> <div class="form-group"> <div class="checkbox checkbox-inline"> <input id="exec-reset-{{mode}}" class="form-control" type="checkbox" - name="entry[resetConsole][{{mode}}]" {{resetConsole_checked}}> + name="entry[resetConsole][{{mode}}]" {{resetConsole_checked}} {{disabled}}> <label for="exec-reset-{{mode}}">{{lang_execResetConsole}}</label> </div> </div> @@ -111,7 +117,7 @@ {{lang_scriptContent}} </label> <textarea id="script-ta" class="form-control" rows="10" - name="entry[script]">{{entry.script}}</textarea> + name="entry[script]" {{disabled}}>{{entry.script}}</textarea> </div> </div> @@ -129,7 +135,7 @@ </ul> <div class="buttonbar text-right"> - <button type="submit" class="btn btn-primary"> + <button type="submit" class="btn btn-primary" {{disabled}}> <span class="glyphicon glyphicon-floppy-disk"></span> {{lang_save}} </button> |