mirror of
https://github.com/retspen/webvirtcloud
synced 2024-12-25 15:45:23 +00:00
1cbdf76df6
* Log for failed login attempts * Logger configuration for logging to file * interface fixes * login log fix, added logged in too * bootstrap icons setup * font-awesome icons replaced with bootstrap icons * replaced i-tags with django_bootstrap_icons * removed icons library from project * bug fix --------- Co-authored-by: catborise <catborise@gmail.com>
37 lines
2 KiB
HTML
37 lines
2 KiB
HTML
{% load i18n %}
|
|
{% load bootstrap_icons %}
|
|
{% if request.user.is_superuser %}
|
|
<a href="#addInstanceOwner" type="button" class="btn btn-success float-end" data-bs-toggle="modal">
|
|
<span aria-hidden="true">{% bs_icon 'plus'%} </span>
|
|
</a>
|
|
|
|
<!-- Modal pool -->
|
|
<div class="modal fade" id="addInstanceOwner" tabindex="-1" role="dialog" aria-labelledby="addInstanceOwnerLabel" aria-hidden="true">
|
|
<div class="modal-dialog">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<h5 class="modal-title">{% trans "Add Instance Owner" %}</h5>
|
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
|
</div>
|
|
<div class="modal-body">
|
|
<form id="add-owner-form" method="post" action="{% url 'instances:add_owner' instance.id %}" role="form" aria-label="Add instance owner form">{% csrf_token %}
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">{% trans "User" %}</label>
|
|
<div class="col-sm-6">
|
|
<select class="form-select" name="user_id">
|
|
{% for user in users %}
|
|
<option value="{{ user.id }}">{{ user.username }}</option>
|
|
{% endfor %}
|
|
</select>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">{% trans "Close" %}</button>
|
|
<button type="submit" class="btn btn-primary" form="add-owner-form">{% trans "Add" %}</button>
|
|
</div>
|
|
</div> <!-- /.modal-content -->
|
|
</div> <!-- /.modal-dialog -->
|
|
</div> <!-- /.modal -->
|
|
{% endif %}
|