summaryrefslogtreecommitdiffstats
path: root/ogcp/templates
diff options
context:
space:
mode:
authorJavier Hernandez <jhernandez@soleta.eu>2024-01-29 10:38:53 +0100
committerOpenGnSys Support Team <soporte-og@soleta.eu>2024-01-29 11:26:08 +0100
commitdb63b6bc60c0c3c75662136e8524e274746c355b (patch)
tree1aa9a7784a0be8b804ff745fe78fed65bf0ab456 /ogcp/templates
parenta45f664905a6bb0d6e6e1510507ef62402f4d21e (diff)
views: Preselect most used oglive
When setting up oglive, preselect oglive that is most used by selected clients. If only one client is selected, preselect that of the client. In the unusual scenario where a client is set with an oglive that is not in the ogserver's list of available oglives, preselect default.
Diffstat (limited to 'ogcp/templates')
-rw-r--r--ogcp/templates/actions/oglive.html25
1 files changed, 25 insertions, 0 deletions
diff --git a/ogcp/templates/actions/oglive.html b/ogcp/templates/actions/oglive.html
index 6b8e8b3..81b70dd 100644
--- a/ogcp/templates/actions/oglive.html
+++ b/ogcp/templates/actions/oglive.html
@@ -17,6 +17,31 @@
{{ macros.cmd_selected_clients(selected_clients) }}
+{% if oglives_set|length > 1 %}
+ <p>Selected clients have different ogLive</p>
+
+ <table class="table table-hover">
+ <thead class="thead-light">
+ <tr>
+ <th>ogLive</th>
+ <th>Clients</th>
+ </tr>
+ </thead>
+ <tbody class="text-left">
+ {% for oglive, clients in oglives_set.items() %}
+ <tr>
+ <th>{{oglive}}</th>
+ <td>
+ {% for client in clients %}
+ {{client}}
+ {% endfor %}
+ </td>
+ </tr>
+ {% endfor %}
+ </tbody>
+ </table>
+{% endif %}
+
{{ wtf.quick_form(form,
action=url_for('action_oglive'),
method='post',