summaryrefslogtreecommitdiffstats
path: root/ogcp/templates/macros.html
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-08-09 19:11:00 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-08-31 15:57:52 +0200
commit29ab4abf0d9ee969801d190eac827dd85083ab74 (patch)
tree213d7616d299a353c33abfb7f07c2cfc669006ca /ogcp/templates/macros.html
parentbf0459a837f955b82da9eb65805f0c424449d921 (diff)
Add current ogServer to scopesForm
With this commit when users select a scope, the ogServer to which it belongs is also sent. Then when processing the form we obtain this ogServer and we can send it the pertinent requests. This commit also makes action "Add client" to use the ogServer sent in the form.
Diffstat (limited to 'ogcp/templates/macros.html')
-rw-r--r--ogcp/templates/macros.html7
1 files changed, 6 insertions, 1 deletions
diff --git a/ogcp/templates/macros.html b/ogcp/templates/macros.html
index 28c4f5a..f67b1a6 100644
--- a/ogcp/templates/macros.html
+++ b/ogcp/templates/macros.html
@@ -23,7 +23,12 @@
{% macro scopes_tree_collapse_level(scopes, parent_id, state) -%}
{% for scope in scopes %}
<li id="{{ scope["name"]|replace(".", "_")|replace(" ", "_") }}_{{ scope["id"] }}" class="nav-item">
- {% if scope["type"] == "room" %}
+ {% if scope["type"] == "server" %}
+ <input class="form-check-input" type="checkbox" form="scopesForm"
+ value="{{ scope["server_ip_port"] }}" onclick="return false;"
+ {% if scope.get("selected", False) %}checked{% endif %}
+ name="scope-server" hidden/>
+ {% elif scope["type"] == "room" %}
<input class="form-check-input" type="checkbox" form="scopesForm"
value="{{ scope["id"] }}"
{% if state %}style="filter: grayscale(100%);" onclick="return false;"{% endif %}