diff options
author | Simon Rettberg | 2019-10-16 18:12:17 +0200 |
---|---|---|
committer | Simon Rettberg | 2019-10-16 18:12:17 +0200 |
commit | 36e47dcdfb7d19d4c8982a77b4dd3b87d8c4ca31 (patch) | |
tree | 1326851106dd111dc1bcd32d0622dda094f1dcae /modules-available/minilinux/templates | |
parent | [dozmod] Increase sat DB's launch counter on cache hit (diff) | |
download | slx-admin-36e47dcdfb7d19d4c8982a77b4dd3b87d8c4ca31.tar.gz slx-admin-36e47dcdfb7d19d4c8982a77b4dd3b87d8c4ca31.tar.xz slx-admin-36e47dcdfb7d19d4c8982a77b4dd3b87d8c4ca31.zip |
[serversetup-bwlp-ipxe/minilinux] Implement minilinux hook for ipxe
Diffstat (limited to 'modules-available/minilinux/templates')
5 files changed, 91 insertions, 56 deletions
diff --git a/modules-available/minilinux/templates/branches.html b/modules-available/minilinux/templates/branches.html index 1ba9497c..64adda16 100644 --- a/modules-available/minilinux/templates/branches.html +++ b/modules-available/minilinux/templates/branches.html @@ -1,17 +1,19 @@ +<h3>{{lang_branchesHeading}}</h3> {{#branches}} <div id="ibm-mainframe" class="panel panel-default"> <div class="panel-heading"> <div class="pull-right"> {{sourceid}} {{branchid}} </div> - {{title}} + <b>{{title}}</b> </div> <div class="panel-body"> - + {{description}} </div> {{{versionlist}}} </div> {{/branches}} + <script> document.addEventListener('DOMContentLoaded', function () { var addHandlers = function(parent) { @@ -44,13 +46,21 @@ }; $('.version-link').click(function(e) { e.preventDefault(); - $(this).removeClass('version-link').off().removeAttr('href'); - loadDetails($(this).data('version'), { show: "version" }); + var ver = $(this).data('version'); + var c = $('.version-container[data-version="' + ver + '"]'); + if (c.is(':visible')) { + c.hide(); + } else if (c.is(':empty')) { + loadDetails(ver, {show: "version"}); + } else { + c.show(); + } }); addHandlers($('#ibm-mainframe')); $('[data-autoclick="true"]').click(); }); var taskDone = {}; + var wasUnfinished = false; function dlTmCb(task) { if (!task.data || !task.data.files) return; @@ -69,5 +79,7 @@ taskDone[id] = wasDone ? true : f.progress; } } + if (wasUnfinished && task.statusCode === 'TASK_FINISHED') location.reload(true); + if (task.statusCode !== 'TASK_FINISHED') wasUnfinished = true; } </script>
\ No newline at end of file diff --git a/modules-available/minilinux/templates/filelist.html b/modules-available/minilinux/templates/filelist.html index 2c26edf9..9aa175bd 100644 --- a/modules-available/minilinux/templates/filelist.html +++ b/modules-available/minilinux/templates/filelist.html @@ -50,4 +50,8 @@ {{#dltask}} <div class="hidden" data-tm-id="{{dltask}}" data-tm-callback="dlTmCb"></div> {{/dltask}} +{{#changelog}} +<h4>{{lang_changelog}}</h4> +{{changelog}} +{{/changelog}} <div class="slx-space"></div>
\ No newline at end of file diff --git a/modules-available/minilinux/templates/page-minilinux.html b/modules-available/minilinux/templates/page-minilinux.html index 2cbde608..3059e827 100644 --- a/modules-available/minilinux/templates/page-minilinux.html +++ b/modules-available/minilinux/templates/page-minilinux.html @@ -1,3 +1,5 @@ <h1>{{lang_minilinuxHeading}}</h1> -<p>{{lang_introText}}</p>
\ No newline at end of file +<p>{{lang_introText}}</p> + +{{lang_selectedDefaultIs}}: <b>{{default}}</b>
\ No newline at end of file diff --git a/modules-available/minilinux/templates/sources.html b/modules-available/minilinux/templates/sources.html index f2e54745..dabc7f4d 100644 --- a/modules-available/minilinux/templates/sources.html +++ b/modules-available/minilinux/templates/sources.html @@ -1,42 +1,41 @@ -<div class="panel panel-default"> - <div class="panel-heading"> - {{lang_sources}} - </div> - <table class="table table-condensed"> - <thead> - <tr> - <th>{{lang_id}}</th> - <th>{{lang_title}}</th> - <th>{{lang_url}}</th> - <th>{{lang_lastUpdate}}</th> - <th>{{lang_key}}</th> - </tr> - </thead> - <tbody> - {{#list}} - <tr> - <td class="small">{{sourceid}}</td> - <td>{{title}}</td> - <td class="small">{{url}}</td> - <td class="{{update_class}}">{{lastupdate_s}}</td> - <td class="text-center"> - <button type="button" class="btn btn-default btn-xs" data-confirm="#confirm-{{source}}" data-close="{{lang_close}}"> - <span class="glyphicon glyphicon-eye-open"></span> - </button> - <pre id="confirm-{{source}}" class="hidden">{{pubkey}}</pre> - </td> - </tr> - {{/list}} - </tbody> - </table> - <div class="panel-body text-right"> - <form method="post" action="?do=minilinux"> - <input type="hidden" name="token" value="{{token}}"> - <button type="submit" name="show" value="updatesources" class="btn btn-default" - onclick="$(this).find('.glyphicon').addClass('slx-rotation')" {{^show_refresh}}disabled{{/show_refresh}}> - <span class="glyphicon glyphicon-refresh"></span> - {{lang_updateSourcesButton}} +<h3>{{lang_sources}}</h3> + +<p>{{lang_sourcesIntro}}</p> + +<table class="table table-condensed"> + <thead> + <tr> + <th>{{lang_id}}</th> + <th>{{lang_title}}</th> + <th>{{lang_url}}</th> + <th>{{lang_lastUpdate}}</th> + <th>{{lang_key}}</th> + </tr> + </thead> + <tbody> + {{#list}} + <tr> + <td class="small">{{sourceid}}</td> + <td>{{title}}</td> + <td class="small">{{url}}</td> + <td class="{{update_class}}">{{lastupdate_s}}</td> + <td class="text-center"> + <button type="button" class="btn btn-default btn-xs" data-confirm="#confirm-{{source}}" data-close="{{lang_close}}"> + <span class="glyphicon glyphicon-eye-open"></span> </button> - </form> - </div> + <pre id="confirm-{{source}}" class="hidden">{{pubkey}}</pre> + </td> + </tr> + {{/list}} + </tbody> +</table> +<div class="text-right"> + <form method="post" action="?do=minilinux"> + <input type="hidden" name="token" value="{{token}}"> + <button type="submit" name="show" value="updatesources" class="btn btn-default" + onclick="$(this).find('.glyphicon').addClass('slx-rotation')" {{^show_refresh}}disabled{{/show_refresh}}> + <span class="glyphicon glyphicon-refresh"></span> + {{lang_updateSourcesButton}} + </button> + </form> </div>
\ No newline at end of file diff --git a/modules-available/minilinux/templates/versionlist.html b/modules-available/minilinux/templates/versionlist.html index 1e5c7c96..4ef4e631 100644 --- a/modules-available/minilinux/templates/versionlist.html +++ b/modules-available/minilinux/templates/versionlist.html @@ -1,22 +1,45 @@ <table class="table table-striped"> <tr> - <th>{{lang_version}}</th> - <th>{{lang_releaseDate}}</th> + <th class="slx-smallcol">{{lang_version}}</th> + <th class="slx-smallcol">{{lang_releaseDate}}</th> <th>{{lang_title}}</th> <th class="slx-smallcol"></th> <th class="slx-smallcol"></th> + <th class="slx-smallcol"></th> </tr> {{#versions}} <tr> - <td> + <td class="text-nowrap"> <a href="#" class="version-link" data-version="{{versionid}}" {{#downloading}}data-autoclick="true"{{/downloading}}> {{versionid}} <b class="caret"></b> </a> </td> - <td>{{dateline_s}}</td> + <td class="text-nowrap">{{dateline_s}}</td> <td>{{title}}</td> - <td> + <td class="text-nowrap"> + {{#orphan}} + {{lang_orphanedVersion}} + {{/orphan}} + </td> + <td class="text-nowrap text-center {{default_class}}"> + {{#showsetdefault}} + <form method="post" action="?do=minilinux" style="margin:0;padding:0;display:inline"> + <input type="hidden" name="token" value="{{token}}"> + <input type="hidden" name="version" value="{{versionid}}"> + <button type="submit" name="show" value="setdefault" class="btn btn-xs btn-info"> + <span class="glyphicon glyphicon-flag"></span> + </button> + </form> + {{/showsetdefault}} + {{#isdefault}} + <span class="glyphicon glyphicon-ok"></span> + {{/isdefault}} + </td> + <td class="text-nowrap text-center"> + {{#installed}} + <span class="btn btn-default btn-xs disabled">{{lang_installed}}</span> + {{/installed}} {{^installed}} {{^downloading}} <button type="button" class="btn btn-xs btn-success btn-download" data-version="{{versionid}}"> @@ -26,14 +49,9 @@ {{/downloading}} {{/installed}} </td> - <td> - {{#orphan}} - {{lang_orphanedVersion}} - {{/orphan}} - </td> </tr> <tr> - <td colspan="5" class="version-container collapse" data-version="{{versionid}}"></td> + <td colspan="6" class="version-container collapse" data-version="{{versionid}}"></td> </tr> {{/versions}} </table>
\ No newline at end of file |