mirror of
https://github.com/retspen/webvirtcloud
synced 2025-07-31 12:41:08 +00:00
bootstrap 4.5 & Bootswatch Themes
This commit is contained in:
parent
e2b7b77da0
commit
0e5840498e
230 changed files with 19531 additions and 5077 deletions
|
|
@ -1,7 +1,7 @@
|
|||
{% load i18n %}
|
||||
{% if request.user.is_superuser %}
|
||||
<a href="#AddQos{{ id }}" type="button" class="btn btn-sm btn-success pull-right" data-toggle="modal" title="add qos">
|
||||
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
||||
<a href="#AddQos{{ id }}" type="button" class="btn btn-success float-right" data-toggle="modal" title="add qos">
|
||||
<span class="fa fa-plus" aria-hidden="true"></span>
|
||||
</a>
|
||||
|
||||
<!-- Modal pool -->
|
||||
|
|
@ -10,35 +10,35 @@
|
|||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">{% trans "Add Qos for Network" %}</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title">{% trans "Add Inbound Qos for Network" %}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Direction" %}:</label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Direction" %}:</label>
|
||||
<div class="col-sm-6">
|
||||
<select class="form-control" name="qos_direction">
|
||||
<select class="custom-select" name="qos_direction">
|
||||
<option value="inbound">{% trans 'Inbound' %}</option>
|
||||
<option value="outbound">{% trans 'Outbound' %}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Average" %}:</label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Average" %}:</label>
|
||||
<div class="col-sm-6">
|
||||
<input class="form-control" name="qos_average" placeholder="kilobytes"
|
||||
required pattern="[0-9]+"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Peak" %}:</label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Peak" %}:</label>
|
||||
<div class="col-sm-6">
|
||||
<input class="form-control" name="qos_peak" placeholder="kilobytes"
|
||||
pattern="[0-9]+"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Burst" %}:</label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Burst" %}:</label>
|
||||
<div class="col-sm-6">
|
||||
<input class="form-control" name="qos_burst" placeholder="kilobytes"
|
||||
pattern="[0-9]+"/>
|
||||
|
|
@ -47,7 +47,7 @@
|
|||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{% trans 'Close' %}</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">{% trans 'Close' %}</button>
|
||||
<button type="submit" class="btn btn-primary" name="set_qos">{% trans 'Save' %}</button>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{% load i18n %}
|
||||
{% if request.user.is_superuser %}
|
||||
<a href="#AddNetPool" type="button" class="btn btn-success pull-right" data-toggle="modal">
|
||||
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
||||
<a href="#AddNetPool" type="button" class="btn btn-success float-right" data-toggle="modal">
|
||||
<span class="fa fa-plus" aria-hidden="true"></span>
|
||||
</a>
|
||||
|
||||
<!-- Modal pool -->
|
||||
|
|
@ -9,21 +9,21 @@
|
|||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">{% trans "Add New Network" %}</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title">{% trans "Add New Network" %}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form class="form-horizontal" method="post" action="" role="form" novalidate>{% csrf_token %}
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Name" %}</label>
|
||||
<form method="post" action="" role="form" novalidate>{% csrf_token %}
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="name" placeholder="default" required pattern="[a-zA-Z0-9_]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Type forwarding" %}</label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Type forwarding" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<select id="forward_select" class="form-control" name="forward">
|
||||
<select id="forward_select" class="custom-select" name="forward">
|
||||
<option value="nat">{% trans "NAT" %}</option>
|
||||
<option value="route">{% trans "ROUTE" %}</option>
|
||||
<option value="none">{% trans "ISOLATE" %}</option>
|
||||
|
|
@ -31,57 +31,57 @@
|
|||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 control-label">{% trans "IPv4 Subnet pool" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 col-form-label">{% trans "IPv4 Subnet pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="subnet" value="" placeholder="192.168.100.0/24" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 control-label">{% trans "DHCPv4" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 col-form-label">{% trans "DHCPv4" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="checkbox" name="dhcp4" value="true" checked>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 control-label">{% trans "Fixed Address" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Fixed Address" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="checkbox" name="fixed" value="true">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 control-label">{% trans "Enable IPv6" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Enable IPv6" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="checkbox" id="enable_ipv6" name="enable_ipv6" value="false">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp ipv6_group">
|
||||
<label class="col-sm-4 control-label">{% trans "IPv6 Subnet pool" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp ipv6_group">
|
||||
<label class="col-sm-4 col-form-label">{% trans "IPv6 Subnet pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="subnet6" value="" placeholder="fd00:dead:baba:1::/64" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group_dhcp ipv6_group">
|
||||
<label class="col-sm-4 control-label">{% trans "DHCPv6" %}</label>
|
||||
<div class="form-group row bridge_name_form_group_dhcp ipv6_group">
|
||||
<label class="col-sm-4 col-form-label">{% trans "DHCPv6" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="checkbox" name="dhcp6" value="true">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group">
|
||||
<label class="col-sm-4 control-label">{% trans "Bridge Name" %}</label>
|
||||
<div class="form-group row bridge_name_form_group">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Bridge Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="bridge_name" placeholder="br0" pattern="[a-z0-9\-_:]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group bridge_name_form_group">
|
||||
<label class="col-sm-4 control-label">{% trans "Open vSwitch" %}</label>
|
||||
<div class="form-group row bridge_name_form_group">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Open vSwitch" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="checkbox" name="openvswitch" value="true">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<button type="submit" class="btn btn-primary" name="create">{% trans "Create" %}</button>
|
||||
</div>
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{% load i18n %}
|
||||
{% if request.user.is_superuser %}
|
||||
<a href="#AddFixedNet4" type="button" class="btn btn-success pull-right" data-toggle="modal">
|
||||
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
||||
<a href="#AddFixedNet4" type="button" class="btn btn-success float-right" data-toggle="modal">
|
||||
<span class="fa fa-plus" aria-hidden="true"></span>
|
||||
</a>
|
||||
|
||||
<!-- Modal pool -->
|
||||
|
|
@ -9,41 +9,39 @@
|
|||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">{% trans "Add IPv4 Fixed Address" %}</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title">{% trans "Add IPv4 Fixed Address" %}</h4>
|
||||
</div>
|
||||
<form method="post" action="" role="form">{% csrf_token %}
|
||||
<form method="post" action="" role="form">{% csrf_token %}
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Subnet Pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" readonly class="form-control" name="subnet" value="{{ ipv4_network }}" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Subnet Pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" readonly class="form-control" name="subnet" value="{{ ipv4_network }}" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "MAC" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="mac" required pattern="[0-9\/\:]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "MAC" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="mac" required pattern="[0-9\/\:]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="name" pattern="[a-zA-Z0-9_]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="name" pattern="[a-zA-Z0-9_]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Address" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="address" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Address" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="address" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<input name="family" value="ipv4" hidden/>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<input name="family" value="ipv4" hidden/>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<button type="submit" class="btn btn-primary" name="modify_fixed_address">{% trans "Create" %}</button>
|
||||
</div>
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{% load i18n %}
|
||||
{% if request.user.is_superuser %}
|
||||
<a href="#AddFixedNet6" type="button" class="btn btn-success pull-right" data-toggle="modal">
|
||||
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
||||
<a href="#AddFixedNet6" type="button" class="btn btn-success float-right" data-toggle="modal">
|
||||
<span class="fa fa-plus" aria-hidden="true"></span>
|
||||
</a>
|
||||
|
||||
<!-- Modal pool -->
|
||||
|
|
@ -9,41 +9,39 @@
|
|||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title">{% trans "Add IPV6 Fixed Address" %}</h4>
|
||||
<h5 class="modal-title">{% trans "Add IPV6 Fixed Address" %}</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
</div>
|
||||
<form method="post" action="" role="form">{% csrf_token %}
|
||||
<form method="post" action="" role="form">{% csrf_token %}
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Subnet Pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" readonly class="form-control" name="subnet" value="{{ ipv6_network }}" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Subnet Pool" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" readonly class="form-control" name="subnet" value="{{ ipv6_network }}" required pattern="[0-9\/\.]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "ID" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="id" required pattern="[0-9a-fA-F\/\:]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "ID" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="id" required pattern="[0-9a-fA-F\/\:]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="name" pattern="[a-zA-Z0-9_]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="name" pattern="[a-zA-Z0-9_]+">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label">{% trans "Address" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="address" required pattern="[a-fA-F0-9\/\:]+">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-4 col-form-label">{% trans "Address" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" name="address" required pattern="[a-fA-F0-9\/\:]+">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<input name="family" value="ipv6" hidden/>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<div class="modal-footer">
|
||||
<input name="family" value="ipv6" hidden/>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">{% trans "Close" %}</button>
|
||||
<button type="submit" class="btn btn-primary" name="modify_fixed_address">{% trans "Create" %}</button>
|
||||
</div>
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -6,30 +6,32 @@
|
|||
<!-- Page Heading -->
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h1 class="page-header">{% trans "Network:" %} {{ pool }}</h1>
|
||||
<ol class="breadcrumb">
|
||||
<li class="active">
|
||||
<i class="fa fa-dashboard"></i> <a href="{% url 'overview' compute.id %}">{% trans "Overview" %}</a>
|
||||
<h2 class="page-header">{% trans "Network" %}: {{ pool }}</h2>
|
||||
|
||||
<ol class="breadcrumb bg-light shadow-sm">
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'overview' compute.id %}"><i class="fa fa-dashboard"></i> {% trans "Overview" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-server"></i> <a href="{% url 'instances' compute.id %}">{% trans "Instances" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'instances' compute.id %}"><i class="fa fa-server"></i> {% trans "Instances" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-hdd-o"></i> <a href="{% url 'storages' compute.id %}">{% trans "Storages" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'storages' compute.id %}"><i class="fa fa-hdd-o"></i> {% trans "Storages" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-sitemap"></i> <a href="{% url 'networks' compute.id %}">{% trans "Networks" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'networks' compute.id %}"><i class="fa fa-sitemap"></i> {% trans "Networks" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-wifi"></i> <a href="{% url 'interfaces' compute.id %}">{% trans "Interfaces" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'interfaces' compute.id %}"><i class="fa fa-wifi"></i> {% trans "Interfaces" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-filter"></i> <a href="{% url 'nwfilters' compute.id %}">{% trans "NWFilters" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'nwfilters' compute.id %}"><i class="fa fa-filter"></i> {% trans "NWFilters" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-key"></i> <a href="{% url 'secrets' compute.id %}">{% trans "Secrets" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'secrets' compute.id %}"><i class="fa fa-key"></i> {% trans "Secrets" %}</a>
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.row -->
|
||||
|
|
@ -38,362 +40,333 @@
|
|||
{% include 'messages_block.html' %}
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>{% trans "Network Name" %}:</p>
|
||||
<p>{% trans "Device" %}:</p>
|
||||
<p>{% trans "MAC" %}:</p>
|
||||
<p>{% trans "State" %}:</p>
|
||||
<p>{% trans "Autostart" %}:</p>
|
||||
</div>
|
||||
<div class="col-xs-6 col-sm-6">
|
||||
<p>{{ pool }}</p>
|
||||
<p>{{ device }}</p>
|
||||
<p>{{ net_mac }}</p>
|
||||
<p>
|
||||
<dl class="ml-3 row">
|
||||
<dt class="col-6">{% trans "Network name" %}</dt>
|
||||
<dd class="col-6">{{ pool }}</dd>
|
||||
<dt class="col-6">{% trans "Device" %}</dt>
|
||||
<dd class="col-6">{{ device }}</dd>
|
||||
<dt class="col-6">{% trans "State" %}</dt>
|
||||
<dd class="col-6">
|
||||
<form action="" method="post" role="form">{% csrf_token %}
|
||||
{% ifequal state 0 %}
|
||||
<input type="submit" class="btn btn-xs btn-default" name="start" value="{% trans "Start" %}">
|
||||
<input type="submit" class="btn btn-xs btn-default" name="delete" value="{% trans "Delete" %}" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<input type="submit" class="btn btn-sm btn-success" name="start" value="{% trans "Start" %}">
|
||||
<input type="submit" class="btn btn-sm btn-danger" name="delete" value="{% trans "Delete" %}" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
{% else %}
|
||||
<input type="submit" class="btn btn-xs btn-default" name="stop" value="{% trans "Stop" %}" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<input type="submit" class="btn btn-sm btn-secondary" name="stop" value="{% trans "Stop" %}" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
{% endifequal %}
|
||||
</form>
|
||||
</p>
|
||||
<p>
|
||||
</dd>
|
||||
<dt class="col-6">{% trans "Autostart" %}</dt>
|
||||
<dd class="col-6">
|
||||
<form action="" method="post" role="form">{% csrf_token %}
|
||||
{% ifequal autostart 0 %}
|
||||
<input type="submit" class="btn btn-xs btn-default" name="set_autostart" value="{% trans "Enable" %}">
|
||||
<input type="submit" class="btn btn-sm btn-success" name="set_autostart" value="{% trans "Enable" %}">
|
||||
{% else %}
|
||||
<input type="submit" class="btn btn-xs btn-default" name="unset_autostart" onclick="return confirm('{% trans "Are you sure?" %}')" value="{% trans "Disable" %}">
|
||||
<input type="submit" class="btn btn-sm btn-secondary" name="unset_autostart" onclick="return confirm('{% trans "Are you sure?" %}')" value="{% trans "Disable" %}">
|
||||
{% endifequal %}
|
||||
</form>
|
||||
</p>
|
||||
</div>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<h3 class="page-header"></h3>
|
||||
</div>
|
||||
<div class="panel-group" id="accordion">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<a data-toggle="collapse" data-parent="#accordion" href="#collapseOne">
|
||||
{% trans 'XML' %}
|
||||
</a>
|
||||
</div>
|
||||
<div id="collapseOne" class="panel-collapse collapse">
|
||||
<div class="panel-body">
|
||||
<form class="form-inline" method="post" role="form">{% csrf_token %}
|
||||
<div class="col-xs-12" id="xmlheight">
|
||||
<div class="col-lg-12">
|
||||
<button class="btn btn-block btn-light" role="button" data-toggle="collapse" data-target="#collapseXML" aria-expanded="true" aria-controls="collapseXML">
|
||||
<span class="fa fa-chevron-down"></span>
|
||||
{% trans 'XML' %}
|
||||
</button>
|
||||
<div class="collapse" id="collapseXML">
|
||||
<div class="card card-body">
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<div id="xmlheight">
|
||||
<input type="hidden" name="edit_xml"/>
|
||||
<textarea id="edit_editor">{{ xml }}</textarea>
|
||||
</div>
|
||||
<button type="submit" class="btn btn-primary pull-right" name="edit_network">
|
||||
</div>
|
||||
<button type="submit" class="btn btn-primary float-right" name="edit_network">
|
||||
{% trans "Edit" %}
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<h3 class="page-header">{% trans "IPv4 Configuration" %}</h3>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>{% trans "IPv4 Forwarding" %}:</p>
|
||||
<p>{% trans "Network" %}:</p>
|
||||
<p>{% trans "DHCP" %}:</p>
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
<p>{% trans "Start" %}:</p>
|
||||
<p>{% trans "End" %}:</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>
|
||||
{% ifequal net_forward.0 'nat' %}
|
||||
{% trans "NAT" %}
|
||||
{% endifequal %}
|
||||
{% ifequal net_forward.0 'route' %}
|
||||
{% trans "ROUTE" %}
|
||||
{% endifequal %}
|
||||
{% ifequal net_forward.0 'bridge' %}
|
||||
{% trans "BRIDGE" %}
|
||||
{% endifequal %}
|
||||
{% if not net_forward.0 %}
|
||||
{% trans "ISOLATE" %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p>{{ ipv4_network|default:"-" }}</p>
|
||||
<p>
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
<span class="text-success">{% trans "ON" %}</span>
|
||||
{% else %}
|
||||
<span class="text-danger">{% trans "OFF" %}</span>
|
||||
{% endif %}
|
||||
</p>
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
{% if state %}
|
||||
<p>{{ ipv4_dhcp_range_start }}</p>
|
||||
<p>{{ ipv4_dhcp_range_end }}</p>
|
||||
{% else %}
|
||||
<p><input name="range_start" value="{{ ipv4_dhcp_range_start }}"/></p>
|
||||
<p><input name="range_end" value="{{ ipv4_dhcp_range_end }}"/></p>
|
||||
<input hidden name="family" value="ipv4"/>
|
||||
<div class="col-xs-10 col-sm-8">
|
||||
<input type="submit" class="btn btn-primary btn-block" value="Apply"
|
||||
name="modify_dhcp_range"
|
||||
title="Edit DHCP Range" onclick="return confirm('{% trans "Are you sure?" %}')"/>
|
||||
</div>
|
||||
{% endif %}
|
||||
</form>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h5 class="page-header">{% trans "IPv4 Configuration" %}</h5>
|
||||
|
||||
<dl class="ml-3 row">
|
||||
<dt class="col-6">{% trans "IPv4 Forwarding" %}</dt>
|
||||
<dd class="col-6">
|
||||
{% ifequal net_forward.0 'nat' %}
|
||||
{% trans "NAT" %}
|
||||
{% endifequal %}
|
||||
{% ifequal net_forward.0 'route' %}
|
||||
{% trans "ROUTE" %}
|
||||
{% endifequal %}
|
||||
{% ifequal net_forward.0 'bridge' %}
|
||||
{% trans "BRIDGE" %}
|
||||
{% endifequal %}
|
||||
{% if not net_forward.0 %}
|
||||
{% trans "ISOLATE" %}
|
||||
{% endif %}
|
||||
</dd>
|
||||
<dt class="col-6">{% trans "Network" %}</dt>
|
||||
<dd class="col-6">{{ ipv4_network|default:"-" }}</dd>
|
||||
<dt class="col-6">{% trans "DHCP" %}:</dt>
|
||||
<dd class="col-6">
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
<span class="text-success">{% trans "ON" %}</span>
|
||||
{% else %}
|
||||
<span class="text-danger">{% trans "OFF" %}</span>
|
||||
{% endif %}
|
||||
</dd>
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
{% if state %}
|
||||
<dt class="col-6">{% trans "Start" %}</dt>
|
||||
<dd class="col-6">{{ ipv4_dhcp_range_start }}</dd>
|
||||
<dt class="col-6">{% trans "End" %}</dt>
|
||||
<dd class="col-6">{{ ipv4_dhcp_range_end }}</dd>
|
||||
{% else %}
|
||||
<form class="form-inline col-lg-12 pl-0" method="post" role="form">{% csrf_token %}
|
||||
<dt class="col-6">{% trans "Start" %}</dt>
|
||||
<dd class="col-6"><input name="range_start" value="{{ ipv4_dhcp_range_start }}"/></dd>
|
||||
<dt class="col-6">{% trans "End" %}</dt>
|
||||
<dd class="col-6"><input name="range_end" value="{{ ipv4_dhcp_range_end }}"/></dd>
|
||||
<dt class="col-6"></dt>
|
||||
<dd class="col-6 ">
|
||||
<input type="submit"
|
||||
class="btn btn-primary"
|
||||
value="Apply"
|
||||
name="modify_dhcp_range"
|
||||
title="Edit DHCP Range"
|
||||
onclick="return confirm('{% trans "Are you sure?" %}')"/>
|
||||
</dd>
|
||||
<input hidden name="family" value="ipv4"/>
|
||||
</form>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</dl>
|
||||
|
||||
{% if ipv4_dhcp_range_start and ipv4_dhcp_range_end %}
|
||||
{% if state %}
|
||||
{% include 'modify_ipv4_fixed_address.html' %}
|
||||
{% endif %}
|
||||
<div class="row">
|
||||
<h3 class="page-header">{% trans "IPv4 Fixed Address" %}</h3>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if ipv4_fixed_address %}
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="panel-group" id="accordion">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<a data-toggle="collapse" data-parent="#accordion" href="#collapseTwo">
|
||||
{% trans 'Show' %}
|
||||
</a>
|
||||
</div>
|
||||
<div id="collapseTwo" class="panel-collapse collapse">
|
||||
<div class="panel-body">
|
||||
<div class="input-append form-inline pull-right">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" id="filter_input">
|
||||
</div>
|
||||
<input type="button" class="btn btn-default" id="filter_button" value="Filter">
|
||||
<button type="button" class="btn btn-default" id="filter_clear">{% trans 'Clear' %}</button>
|
||||
</div>
|
||||
<table id="ipv4_table" class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="text-align: center">{% trans "MAC" %}</th>
|
||||
<th style="text-align: center">{% trans "Address" %}</th>
|
||||
<th style="text-align: center">{% trans "Name" %}</th>
|
||||
<th style="text-align: center">{% trans "Action" %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody style="text-align: center">
|
||||
{% for fix4 in ipv4_fixed_address %}
|
||||
<tr>
|
||||
<td>
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<td><input class="form-control" value="{{ fix4.mac }}" name="mac" readonly/></td>
|
||||
<td><input class="form-control" value="{{ fix4.ip }}" name="address" /></td>
|
||||
<td><input class="form-control" value="{{ fix4.name }}" name="name" /></td>
|
||||
<td>
|
||||
<input hidden name="family" value="ipv4"/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="modify_fixed_address"
|
||||
title="Edit entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="delete_fixed_address"
|
||||
title="Delete entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="row">
|
||||
<h3 class="page-header">{% trans "IPv6 Configuration" %}</h3>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>{% trans "IPv6 Forwarding" %}:</p>
|
||||
<p>{% trans "Network" %}:</p>
|
||||
<p>{% trans "DHCP" %}:</p>
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
<p>{% trans "Start" %}:</p>
|
||||
<p>{% trans "End" %}:</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>
|
||||
{% if not net_forward.0 %}
|
||||
{% trans "ISOLATE" %}
|
||||
{% else %}
|
||||
{% trans "ROUTE" %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p>{{ ipv6_network|default:"-" }}</p>
|
||||
<p>
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
<span class="text-success">{% trans "ON" %}</span>
|
||||
{% else %}
|
||||
<span class="text-danger">{% trans "OFF" %}</span>
|
||||
{% endif %}
|
||||
</p>
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
{% if state %}
|
||||
<p>{{ ipv6_dhcp_range_start }}</p>
|
||||
<p>{{ ipv6_dhcp_range_end }}</p>
|
||||
{% else %}
|
||||
<p><input name="range_start" value="{{ ipv6_dhcp_range_start }}"/></p>
|
||||
<p><input name="range_end" value="{{ ipv6_dhcp_range_end }}"/></p>
|
||||
<input hidden name="family" value="ipv6"/>
|
||||
<div class="col-xs-10 col-sm-8">
|
||||
<input type="submit" class="btn btn-primary btn-block" value="Apply"
|
||||
name="modify_dhcp_range"
|
||||
title="Edit DHCP Range" onclick="return confirm('{% trans "Are you sure?" %}')"/>
|
||||
</div>
|
||||
{% endif %}
|
||||
</form>
|
||||
{% endif %}
|
||||
</div>
|
||||
<h5 class="page-header">{% trans "IPv4 Fixed Address" %}</h5>
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% if ipv4_fixed_address %}
|
||||
|
||||
<div class="col-12">
|
||||
<button class="btn btn-block btn-light" role="button" data-toggle="collapse" data-target="#collapseipv4fix" aria-expanded="true" aria-controls="collapseXML">
|
||||
<span class="fa fa-chevron-down"></span>
|
||||
{% trans 'Show' %}
|
||||
</button>
|
||||
<div id="collapseipv4fix" class="collapse">
|
||||
<div class="input-append form-inline float-right">
|
||||
<div class="form-group row">
|
||||
<input type="text" class="form-control" id="filter_input">
|
||||
</div>
|
||||
<input type="button" class="btn btn-secondary" id="filter_button" value="Filter">
|
||||
<button type="button" class="btn btn-secondary" id="filter_clear">{% trans 'Clear' %}</button>
|
||||
</div>
|
||||
|
||||
<table id="ipv4_table" class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{% trans "MAC" %}</th>
|
||||
<th>{% trans "Address" %}</th>
|
||||
<th>{% trans "Name" %}</th>
|
||||
<th>{% trans "Actions" %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for fix4 in ipv4_fixed_address %}
|
||||
<tr>
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<td><input class="form-control" value="{{ fix4.mac }}" name="mac" readonly/></td>
|
||||
<td><input class="form-control" value="{{ fix4.ip }}" name="address" /></td>
|
||||
<td><input class="form-control" value="{{ fix4.name }}" name="name" /></td>
|
||||
<td class="text-nowrap">
|
||||
<input hidden name="family" value="ipv4"/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="modify_fixed_address"
|
||||
title="Edit entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="delete_fixed_address"
|
||||
title="Delete entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</form>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
{% endif %}
|
||||
|
||||
<h5 class="page-header">{% trans "IPv6 Configuration" %}</h5>
|
||||
|
||||
<dl class="ml-3 row">
|
||||
<dt class="col-6">{% trans "IPv6 Forwarding" %}</dt>
|
||||
<dd class="col-6">
|
||||
{% if not net_forward.0 %}
|
||||
{% trans "ISOLATE" %}
|
||||
{% else %}
|
||||
{% trans "ROUTE" %}
|
||||
{% endif %}
|
||||
</dd>
|
||||
<dt class="col-6">{% trans "Network" %}</dt>
|
||||
<dd class="col-6">{{ ipv6_network|default:"-" }}</dd>
|
||||
<dt class="col-6">{% trans "DHCP" %}</dt>
|
||||
|
||||
<dd class="col-6">
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
<span class="text-success">{% trans "ON" %}</span>
|
||||
{% else %}
|
||||
<span class="text-danger">{% trans "OFF" %}</span>
|
||||
{% endif %}
|
||||
</dd>
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
{% if state %}
|
||||
<dt class="col-6">{% trans "Start" %}</dt>
|
||||
<dd class="col-6">{{ ipv6_dhcp_range_start }}</dd>
|
||||
<dt class="col-6">{% trans "End" %}</dt>
|
||||
<dd class="col-6">{{ ipv6_dhcp_range_end }}</dd>
|
||||
{% else %}
|
||||
<form class="form-inline col-lg-12 pl-0" method="post" role="form">{% csrf_token %}
|
||||
<dt class="col-6">{% trans "Start" %}</dt>
|
||||
<dd class="col-6"><input name="range_start" value="{{ ipv6_dhcp_range_start }}"/></dd>
|
||||
<dt class="col-6">{% trans "End" %}</dt>
|
||||
<dd class="col-6"><input name="range_end" value="{{ ipv6_dhcp_range_end }}"/></dd>
|
||||
<dt class="col-6"></dt>
|
||||
<dd class="col-6 ">
|
||||
<input
|
||||
type="submit"
|
||||
class="btn btn-primary btn-block"
|
||||
value="Apply"
|
||||
name="modify_dhcp_range"
|
||||
title="Edit DHCP Range"
|
||||
onclick="return confirm('{% trans "Are you sure?" %}')"/>
|
||||
</dd>
|
||||
<input hidden name="family" value="ipv6"/>
|
||||
</form>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</dl>
|
||||
|
||||
{% if ipv6_dhcp_range_start and ipv6_dhcp_range_end %}
|
||||
{% if state %}
|
||||
{% include 'modify_ipv6_fixed_address.html' %}
|
||||
{% endif %}
|
||||
<div class="row">
|
||||
<h3 class="page-header">{% trans "IPv6 Fixed Address" %}</h3>
|
||||
</div>
|
||||
<h5 class="page-header">{% trans "IPv6 Fixed Address" %}</h5>
|
||||
{% endif %}
|
||||
{% if ipv6_fixed_address %}
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="panel-group" id="accordion">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<a data-toggle="collapse" data-parent="#accordion" href="#collapseIPv6">
|
||||
{% trans 'Show' %}
|
||||
</a>
|
||||
</div>
|
||||
<div id="collapseIPv6" class="panel-collapse collapse">
|
||||
<div class="panel-body">
|
||||
|
||||
<div class="input-append form-inline pull-right">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" id="filter_input_ipv6">
|
||||
</div>
|
||||
<input type="button" class="btn btn-default" id="filter_button_ipv6" value="Filter">
|
||||
<button type="button" class="btn btn-default" id="filter_clear_ipv6">{% trans 'Clear' %}</button>
|
||||
</div>
|
||||
<table id="ipv6_table" class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="text-align: center">{% trans "ID" %}</th>
|
||||
<th style="text-align: center">{% trans "Address" %}</th>
|
||||
<th style="text-align: center">{% trans "Name" %}</th>
|
||||
<th style="text-align: center">{% trans "Action" %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody style="text-align: center">
|
||||
{% for fix6 in ipv6_fixed_address %}
|
||||
<tr>
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<td><input class="form-control" value="{{ fix6.id }}" name="id" readonly/></td>
|
||||
<td><input class="form-control" value="{{ fix6.ip }}" name="address" /></td>
|
||||
<td><input class="form-control" value="{{ fix6.name }}" name="name" /></td>
|
||||
<td>
|
||||
<input hidden name="family" value="ipv6"/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="modify_fixed_address"
|
||||
title="Edit entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="delete_fixed_address"
|
||||
title="Delete entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</form>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% if ipv6_fixed_address %}
|
||||
<div class="col-12">
|
||||
<button class="btn btn-block btn-light" role="button" data-toggle="collapse" data-target="#collapseipv6fix" aria-expanded="true" aria-controls="collapseXML">
|
||||
<span class="fa fa-chevron-down"></span>
|
||||
{% trans 'Show' %}
|
||||
</button>
|
||||
<div id="collapseipv6fix" class="collapse">
|
||||
<div class="input-append form-inline float-right">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" id="filter_input_ipv6">
|
||||
</div>
|
||||
<input type="button" class="btn btn-secondary" id="filter_button_ipv6" value="Filter">
|
||||
<button type="button" class="btn btn-secondary" id="filter_clear_ipv6">{% trans 'Clear' %}</button>
|
||||
</div>
|
||||
<table id="ipv6_table" class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{% trans "ID" %}</th>
|
||||
<th>{% trans "Address" %}</th>
|
||||
<th>{% trans "Name" %}</th>
|
||||
<th>{% trans "Actions" %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for fix6 in ipv6_fixed_address %}
|
||||
<tr>
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<td><input class="form-control" value="{{ fix6.id }}" name="id" readonly/></td>
|
||||
<td><input class="form-control" value="{{ fix6.ip }}" name="address" /></td>
|
||||
<td><input class="form-control" value="{{ fix6.name }}" name="name" /></td>
|
||||
<td class="text-nowrap">
|
||||
<input hidden name="family" value="ipv6"/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="modify_fixed_address"
|
||||
title="Edit entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="delete_fixed_address"
|
||||
title="Delete entry" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</form>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if net_forward.0 == 'route' or net_forward.0 == 'nat' or net_forward.0 == 'isolated' %}
|
||||
{% if state == 0 and qos.items|length != 2%}
|
||||
<form class="form-horizontal" method="post" name="set_qos" role="form">{% csrf_token %}
|
||||
{% include 'add_network_qos.html' %}
|
||||
<form method="post" name="set_qos" role="form">{% csrf_token %}
|
||||
{% include 'add_network_qos.html' %}
|
||||
</form>
|
||||
{% endif %}
|
||||
<h5 class="page-header">{% trans "Qos Configuration" %}</h5>
|
||||
|
||||
<div class="row">
|
||||
<h3 class="page-header">{% trans "Qos Configuration" %}</h3>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<div class="col-sm-12">
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="text-align: center">{% trans "Direction" %}</th>
|
||||
<th style="text-align: center">{% trans "Average" %}</th>
|
||||
<th style="text-align: center">{% trans "Peak" %}</th>
|
||||
<th style="text-align: center">{% trans "Burst" %}</th>
|
||||
<th style="text-align: center">{% trans "Actions" %}</th>
|
||||
<th>{% trans "Direction" %}</th>
|
||||
<th>{% trans "Average" %}</th>
|
||||
<th>{% trans "Peak" %}</th>
|
||||
<th>{% trans "Burst" %}</th>
|
||||
<th>{% trans "Actions" %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for q, att in qos.items %}
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<tr>
|
||||
<td><label class="control-label">{{ q | capfirst }}</label></td>
|
||||
<td><input id="qos_average" class="form-control" name="qos_average"
|
||||
value="{{ att.average|default:'' }}"/></td>
|
||||
<td><input id="qos_peak" class="form-control" name="qos_peak"
|
||||
value="{{ att.peak|default:'' }}"/></td>
|
||||
<td><input id="qos_burst" class="form-control" name="qos_burst"
|
||||
value="{{ att.burst|default:'' }}"/></td>
|
||||
<td>
|
||||
<input name="qos_direction" value="{{ q }}" hidden/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="set_qos" data-toggle="modal"
|
||||
title="Edit Qos" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="unset_qos"
|
||||
title="Delete Qos" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="glyphicon glyphicon-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for q, att in qos.items %}
|
||||
<form method="post" role="form">{% csrf_token %}
|
||||
<tr>
|
||||
<td><label class="col-form-label">{{ q | capfirst }}</label></td>
|
||||
<td><input id="qos_average" class="form-control" name="qos_average"
|
||||
value="{{ att.average|default:'' }}"/>
|
||||
</td>
|
||||
<td><input id="qos_peak" class="form-control" name="qos_peak"
|
||||
value="{{ att.peak|default:'' }}"/>
|
||||
</td>
|
||||
<td><input id="qos_burst" class="form-control" name="qos_burst"
|
||||
value="{{ att.burst|default:'' }}"/>
|
||||
</td>
|
||||
<td class="text-nowrap">
|
||||
<input name="qos_direction" value="{{ q }}" hidden/>
|
||||
<button type="submit" class="btn btn-sm btn-primary"
|
||||
name="set_qos" data-toggle="modal"
|
||||
title="Edit Qos" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-save"></i>
|
||||
</button>
|
||||
<button type="submit" class="btn btn-sm btn-danger"
|
||||
name="unset_qos"
|
||||
title="Delete Qos" onclick="return confirm('{% trans "Are you sure?" %}')">
|
||||
<i class="fa fa-trash"></i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
|
|
|||
|
|
@ -2,34 +2,40 @@
|
|||
{% load i18n %}
|
||||
{% block title %}{% trans "Networks" %} - {{ compute.name }}{% endblock %}
|
||||
{% block content %}
|
||||
<!-- Page Heading -->
|
||||
<!-- Page Heading -->
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
{% include 'create_net_block.html' %}
|
||||
<h1 class="page-header">{{ compute.name }}</h1>
|
||||
<ol class="breadcrumb">
|
||||
<li class="active">
|
||||
<i class="fa fa-dashboard"></i> <a href="{% url 'overview' compute.id %}">{% trans "Overview" %}</a>
|
||||
<h2 class="page-header">{{ compute.name }} - {% trans "Networks" %}</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<nav aria-label="breadcrumb">
|
||||
<ol class="breadcrumb bg-light shadow-sm">
|
||||
<li class="breadcrumb-item active">
|
||||
<a href="{% url 'overview' compute.id %}"><i class="fa fa-dashboard"></i> {% trans "Overview" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-server"></i> <a href="{% url 'instances' compute.id %}">{% trans "Instances" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'instances' compute.id %}"><i class="fa fa-server"></i> {% trans "Instances" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-hdd-o"></i> <a href="{% url 'storages' compute.id %}">{% trans "Storages" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'storages' compute.id %}"><i class="fa fa-hdd-o"></i> {% trans "Storages" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-sitemap"></i> {% trans "Networks" %}
|
||||
<li class="breadcrumb-item">
|
||||
<span class="font-weight-bold"><i class="fa fa-sitemap"></i> {% trans "Networks" %}</span>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-wifi"></i> <a href="{% url 'interfaces' compute.id %}">{% trans "Interfaces" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'interfaces' compute.id %}"><i class="fa fa-wifi"></i> {% trans "Interfaces" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-filter"></i> <a href="{% url 'nwfilters' compute.id %}">{% trans "NWFilters" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'nwfilters' compute.id %}"><i class="fa fa-filter"></i> {% trans "NWFilters" %}</a>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-key"></i> <a href="{% url 'secrets' compute.id %}">{% trans "Secrets" %}</a>
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'secrets' compute.id %}"><i class="fa fa-key"></i> {% trans "Secrets" %}</a>
|
||||
</li>
|
||||
</ol>
|
||||
</nav>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.row -->
|
||||
|
|
@ -41,30 +47,27 @@
|
|||
<div class="col-lg-12">
|
||||
<div class="alert alert-warning alert-dismissable">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
<i class="fa fa-exclamation-triangle"></i><strong>{% trans "Warning" %}:</strong> {% trans "Hypervisor doesn't have any network" %}
|
||||
<i class="fa fa-exclamation-triangle"></i> <strong>{% trans "Warning" %} :</strong> {% trans "Hypervisor doesn't have any Network" %}
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
{% for pool in networks %}
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<div class="panel {% if pool.status %}panel-success{% else %}panel-danger{% endif %} panel-data">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title"><a href="{% url 'network' compute.id pool.name %}">{{ pool.name }}</a></h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-xs-4 col-sm-4">
|
||||
<p><strong>{% trans "Device" %}:</strong></p>
|
||||
<p><strong>{% trans "Forward" %}:</strong></p>
|
||||
</div>
|
||||
<div class="col-xs-6 col-sm-7">
|
||||
<p>{{ pool.device }}</p>
|
||||
<p>{{ pool.forward|upper }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-6 col-md-4">
|
||||
<div class="mb-3 card {% if pool.status %}border-success{% else %}border-danger{% endif %} shadow-sm">
|
||||
<div class="card-header {% if pool.status %}bg-success{% else %}bg-danger{% endif %}">
|
||||
<h6 class="my-0 card-title">
|
||||
<a class="card-link text-light" href="{% url 'network' compute.id pool.name %}">{{ pool.name }}</a></h6>
|
||||
</div>
|
||||
<div class="px-1 card-body">
|
||||
<dl class="row">
|
||||
<dt class="col-6">{% trans "Device" %}</dt>
|
||||
<dd class="col-6">{{ pool.device }}</dd>
|
||||
<dt class="col-6">{% trans "Forward" %}</dt>
|
||||
<dd class="col-6">{{ pool.forward|upper }}</dd>
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue