You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
haproxy-wi/app/templates/configver.html

55 lines
1.8 KiB

{% extends "base.html" %}
{% block content %}
<center>
<h3>Choose server</h3>
<p>
5 years ago
<form action="{{ action }}" method="post">
<input type="hidden" id="service" value="{{service}}">
<a class="ui-button ui-widget ui-corner-all" title="Return back" onclick="history.back()">Back</a>
{% include 'include/select.html' %}
<button type="submit" value="open" name="open" class="btn btn-default">Open</button>
</form>
</p>
{% if not aftersave %}
{% if stderr or error %}
{% include 'include/errors.html' %}
{% endif %}
{% endif %}
{% if open %}
<center>
<h4>Choose old version</h4>
<p>
<select autofocus required name="configver" id="configver">
<option disabled selected>Choose version</option>
{% for file in return_files %}
{% if file == configver %}
<option value="{{file}}" selected>{{file.split('-', maxsplit=1)[1]}}</option>
{% else %}
<option value="{{file}}">{{file.split('-', maxsplit=1)[1]}}</option>
{% endif %}
{% endfor %}
</select>
<input type="hidden" value="{{serv}}" name="serv">
<input type="hidden" value="open" name="open">
<input type="hidden" value="{{service}}" name="service" id="service">
<a class="ui-button ui-widget ui-corner-all" id="show" title="Enter" onclick="showUploadConfig()">Select</a>
</p>
</center>
{% endif %}
{% if aftersave %}
<div class="alert alert-info">Was uploaded old version of config: {{ configver }} </div>
{% if stderr or error %}
{% include 'include/errors.html' %}
{% else %}
<div class="alert alert-success">Config is ok</div>
<a href="viewsttats.py?serv={{ serv }}" target="_blank" title="View stats">Go to view stats</a>
{% endif %}
{% endif %}
</center>
{% if aftersave != 1 %}
<script>
showUploadConfig()
</script>
{% endif %}
{% endblock %}