From 6f5dca59ef87184e7f458551b11053487d54e5e9 Mon Sep 17 00:00:00 2001 From: agames4 Date: Sat, 9 Sep 2023 20:54:36 +0200 Subject: [PATCH] simplified html simplified the ports html for better readability --- sipa/templates/usersuite/_get_port_row.html | 75 +++++++++++++++---- .../usersuite/_port_forwardings.html | 34 +++------ 2 files changed, 71 insertions(+), 38 deletions(-) diff --git a/sipa/templates/usersuite/_get_port_row.html b/sipa/templates/usersuite/_get_port_row.html index 60e13828..7021c260 100644 --- a/sipa/templates/usersuite/_get_port_row.html +++ b/sipa/templates/usersuite/_get_port_row.html @@ -1,46 +1,89 @@ + {% if port_forwarding is not none %} + {% if edit %} - + {{ form.csrf_token }} - + - + - + - + - + + + + - {% else %} - + + + + + + + + + + + + + + + + + {% endif %} +{% else %} + + +
+ {{ form.csrf_token }} - - + + - + - +
- + - +
- +
+ + + + + -{% endif %} + +{% endif %} \ No newline at end of file diff --git a/sipa/templates/usersuite/_port_forwardings.html b/sipa/templates/usersuite/_port_forwardings.html index ff4671a9..e3d2a5bb 100644 --- a/sipa/templates/usersuite/_port_forwardings.html +++ b/sipa/templates/usersuite/_port_forwardings.html @@ -12,35 +12,25 @@

port forwardings

{{ _("option") }} + {% if port_forwadings is not none %} - {% for port_forwad in port_forwardings %} - - - - - - - - - - - - - - - - + {% set port_index = 0 %} + {% for port_forwarding in port_forwardings %} + {% include 'usersuite/_get_port_row.html' %} + {% set port_index = port_index + 1 %} {% endfor %} {% endif %} - - + + + {% else %} - + {% endif %} \ No newline at end of file