Roberto Berto 4 gadi atpakaļ
vecāks
revīzija
27d7de2d43

+ 48 - 0
vycontrol/config/templates/config/instance_edit.html

@@ -0,0 +1,48 @@
+{% extends "base.html" %}
+
+
+{% block content %}
+
+{% if error_message %}<p><strong>{{ error_message }}</strong></p>{% endif %}
+
+
+<p class="margin-topbottom">VyOS vyos-api need to be configurated using vyos cli/ssh according <a href="https://docs.vyos.io/" target="_blank">VyOS documentation</a>.</p>
+
+<form action="{% url 'config:instance-edit' instance.hostname %}" method="post">
+
+
+{% csrf_token %}
+
+<p>
+<label for="alias">Alias</label><br>
+<input type="text" name="alias" id="alias" value="{{ instance.alias }}" size="20">
+</p>
+
+<p>
+<label for="hostname">VyOS API Hosname/IP</label><br>
+<input type="text" name="hostname" id="hostname" value="{{ instance.hostname }}" size="60">
+</p>
+
+<p>
+<label for="port">VyOS API TCP Port</label><br>
+<input type="text" name="port" id="port" value="{{ instance.port }}" size="6">
+</p>
+
+<p>
+<label for="key">VyOS API Key</label><br>
+<input type="text" name="key" id="key" value="{{ instance.key }}" size="60">
+</p>
+
+
+<p>
+<label for="https">VyOS is https?</label><br>
+<input type="checkbox" name="https" id="https" value="1" {% if instance.https == True %}checked="checked"{% endif %}>
+</p>
+
+<input type="submit" value="Edit Instance">
+</form>
+
+
+
+{% endblock %}
+

+ 3 - 2
vycontrol/config/templates/config/users_list.html

@@ -4,11 +4,12 @@
 {{ users }}
 {{ groups }}
 {{ user_groups }}
+{{ username }}
 {% endblock %}
 
 
-{% block header_title %}dnsresolver{% endblock %}
-{% block section_title %}dnsresolver{% endblock %}
+{% block header_title %}Users list{% endblock %}
+{% block section_title %}Users list{% endblock %}
 
 
 {% block content %}

+ 1 - 1
vycontrol/vycontrol/templates/base.html

@@ -50,7 +50,7 @@
               </select>
             
 
-              <span id="menu-username"><a href="{%  url 'accounts:accounts-profile' %}"><i class="material-icons" id="icon-username">person</i>{% block username %}{% endblock %}</a></span> <span id="vycontrol-config-menu"> <a href="{% url 'accounts-logout' %}">Logout</a></span>
+              <span id="menu-username"><a href="{%  url 'accounts:accounts-profile' %}"><i class="material-icons" id="icon-username">person</i>{{ username }}</a></span> <span id="vycontrol-config-menu"> <a href="{% url 'accounts-logout' %}">Logout</a></span>
 
 
           </p>