115 lines
3.2 KiB
HTML
115 lines
3.2 KiB
HTML
{% extends 'base/base.html' %}
|
|
|
|
{% load static %}
|
|
|
|
{% block title %}Управление{% endblock %}
|
|
|
|
{% block heading %}Управление{% endblock %}
|
|
|
|
{% block extra_css %}
|
|
<link rel="stylesheet" href="{% static 'main/css/work.css' %}"/>
|
|
{% endblock %}
|
|
|
|
{% block extra_scripts %}
|
|
<script src="https://unpkg.com/react@17/umd/react.development.js" crossorigin></script>
|
|
<script src="https://unpkg.com/react-dom@17/umd/react-dom.development.js" crossorigin></script>
|
|
<script src="https://unpkg.com/babel-standalone@6/babel.min.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
|
{% endblock%}
|
|
|
|
{% block content %}
|
|
<div class="container-md">
|
|
|
|
<div class="new-section">
|
|
<p class="row page-description">Свободных Мест: {{ licences_remaining }}</p>
|
|
</div>
|
|
|
|
{% block form %}
|
|
<form method="post">
|
|
{% csrf_token %}
|
|
|
|
<div class="row justify-content-center new-section">
|
|
|
|
{% block hidden_form %}
|
|
<div style="display: none">
|
|
{% for field in form.users %}
|
|
{{ field.tag }}
|
|
{% endfor %}
|
|
</div>
|
|
{% endblock %}
|
|
|
|
<div class="col-10">
|
|
<h6 class="table-title">Список сотрудников</h6>
|
|
|
|
{% block table %}
|
|
<table class="light-table">
|
|
|
|
<thead>
|
|
<th>Name</th>
|
|
<th>Email</th>
|
|
<th>Role</th>
|
|
<th>Checked</th>
|
|
</thead>
|
|
|
|
<tbody id="old_tbody">
|
|
{% for user in users %}
|
|
<tr>
|
|
<td><a href="#">{{ user.name }}</a></td>
|
|
<td>{{ user.user.email }}</td>
|
|
<td>{{ user.role }}</td>
|
|
<td class="checkbox_field"></td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
<tbody id="new_tbody"></tbody>
|
|
</table>
|
|
{% endblock%}
|
|
|
|
</div>
|
|
</div>
|
|
|
|
{% block count %}
|
|
<div class="row justify-content-center new-section">
|
|
<div class="col-5">
|
|
<div class="info">
|
|
|
|
<div class="info-row">
|
|
<div class="info-target">Инженеров:</div>
|
|
<div class="info-quantity">
|
|
<div class="status-circle-small light-green"></div>
|
|
<span class="info-quantity-value">{{ engineers }}</span>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="info-row">
|
|
<div class="info-target">Легких агентов:</div>
|
|
<div class="info-quantity">
|
|
<div class="status-circle-small light-yellow"></div>
|
|
<span class="info-quantity-value">{{ light_agents }}</span>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-5">
|
|
|
|
<button type="submit" name="engineer" class="request-acess-button default-button">
|
|
Назначить выбранных на роль инженера
|
|
</button>
|
|
|
|
<button type="submit" name="light_agent" class="hand-over-acess-button default-button">
|
|
Назначить выбранных на роль легкого агента
|
|
</button>
|
|
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|
|
</form>
|
|
{% endblock %}
|
|
</div>
|
|
|
|
<script src="{% static 'main/js/control.js'%}" type="text/babel"></script>
|
|
|
|
{% endblock %}
|