proxadmin/app/templates/settings/profile.html

162 lines
4.5 KiB
HTML
Raw Permalink Normal View History

2017-03-08 13:53:09 -05:00
{% extends "base.html" %}
{% block title %}Edit Profile{% endblock %}
2017-05-24 10:37:52 -04:00
{% block scripts %}
{{ super() }}
<script type="text/javascript">
$(document).ready(function() {
$("#firm").hide();
var chkbox = document.getElementById("{{ form.org_account.id }}");
if (chkbox.checked) {
$("#firm").show();
} else {
$("#firm)").hide();
}
});
$("#{{ form.org_account.id }}").click(function() {
if ($('#{{ form.org_account.id }}').is(':checked')) {
$("#firm").show(); }
else {
$("#firm").hide(); }
});
</script>
{% endblock %}
2017-03-08 13:53:09 -05:00
{% block page_content %}
<div class="row">
2017-05-31 11:20:53 -04:00
{% block sidebar %}
<div class="col-md-4">
<div class="row">
<div class="col-md-12">
{% include "/settings/acc_avatar.html" %}
</div>
<div class="col-md-12">
{% include "/settings/acc_info.html" %}
</div>
</div>
</div>
{% endblock %}
2017-03-08 13:53:09 -05:00
<div class="col-md-8">
<div class="panel panel-default">
2017-05-31 11:20:53 -04:00
<div class="panel-heading">Profile Info</div>
2017-03-08 13:53:09 -05:00
<div class="panel-body">
2017-05-25 01:54:33 -04:00
<form method="POST" action="{{ url_for('settings.profile') }}">
2017-03-08 13:53:09 -05:00
<p>
2017-05-25 01:54:33 -04:00
{{ form.name.label }}<br />{{ form.name(style="width: 80%;") }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.name.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-25 01:54:33 -04:00
{{ form.address.label }}<br /> {{ form.address(style="width: 80%;") }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.address.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-25 01:54:33 -04:00
{{ form.city.label }}<br />{{ form.city(style="width: 80%;") }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.city.errors %}
{{ error }}<br />
{% endfor %}
</p>
2017-05-25 01:54:33 -04:00
<p>
{{ form.country.label }}<br /> {{ form.country(style="width: 80%;") }}<br />
{% for error in form.country.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-24 10:37:52 -04:00
{{ form.postcode.label }}<br />{{ form.postcode }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.postcode.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-24 10:37:52 -04:00
{{ form.phone.label }}<br /> {{ form.phone }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.phone.errors %}
{{ error }}<br />
{% endfor %}
</p>
2017-05-24 10:37:52 -04:00
<p>
{{ form.org_account }} {{ form.org_account.label }}<br />
</p>
2017-03-08 13:53:09 -05:00
</div>
</div>
2017-05-24 10:37:52 -04:00
<div id="firm">
2017-03-08 13:53:09 -05:00
<div class="panel panel-default">
<div class="panel-heading">Данни за юридическо лице</div>
<div class="panel-body">
<p>
2017-05-25 01:54:33 -04:00
{{ form.org_companyname.label }}<br />{{ form.org_companyname(style="width: 80%;") }}<br />
2017-05-24 10:37:52 -04:00
{% for error in form.org_companyname.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-25 01:54:33 -04:00
{{ form.org_regaddress.label }}<br />{{ form.org_regaddress(style="width: 80%;") }}<br />
2017-05-24 10:37:52 -04:00
{% for error in form.org_regaddress.errors %}
{{ error }}<br />
{% endfor %}
</p>
<p>
2017-05-25 01:54:33 -04:00
{{ form.org_responsible.label }}<br />{{ form.org_responsible(style="width: 80%;") }}<br />
2017-03-08 13:53:09 -05:00
{% for error in form.org_responsible.errors %}
{{ error }}<br />
{% endfor %}
</p>
2017-05-24 10:37:52 -04:00
<p>
{{ form.org_vatnum.label }}<br />{{ form.org_vatnum }}<br />
{% for error in form.org_vatnum.errors %}
{{ error }}<br />
{% endfor %}
</p>
2017-03-08 13:53:09 -05:00
</div>
</div>
2017-05-24 10:37:52 -04:00
</div>
2017-03-08 13:53:09 -05:00
<div class="panel panel-default">
<div class="panel-heading">2-Factor Authentication</div>
2017-03-08 13:53:09 -05:00
<div class="panel-body">
<p>
<p>1. Please install <a href="https://fedorahosted.org/freeotp/">FreeOTP</a> on your mobile device. <a href="https://itunes.apple.com/us/app/freeotp/id872559395">iTunes</a> | <a href="https://play.google.com/store/apps/details?id=org.fedorahosted.freeotp">Google Play</a><br />
2. Scan using the application your QR code.<br />
<input type="button" value="Show your QR code" onclick="window.open('{{ url_for('auth.qrcode') }}','popUpWindow','height=500,width=400,left=100,top=100,resizable=yes,scrollbars=yes,toolbar=yes,menubar=no,location=no,directories=no, status=yes');"><br />
3. After the code is properly loaded in the FreeOTP app, you may activate the 2FA login with the following checkbox:</p>
2017-03-08 13:53:09 -05:00
{{ form.twofactor }} {{ form.twofactor.label }}<br />
</p>
</div>
</div>
<p>
{{ form.csrf_token() }}
{{ form.submit }}
</p>
</div>
</div>
</div>
{% endblock %}