77 lines
3.8 KiB
HTML
77 lines
3.8 KiB
HTML
{% extends "base.html" %}
|
|
{% load i18n %}
|
|
{% load render_table from django_tables2 %}
|
|
|
|
{% block title %}{% trans "Staffs" %}{% endblock title %}
|
|
|
|
{% block content %}
|
|
<section class="">
|
|
|
|
<div class="row mt-4">
|
|
<div class="col-auto">
|
|
<div class="d-md-flex justify-content-between">
|
|
<div>
|
|
{% if request.user.userplan %}
|
|
<a href="{% url 'user_create' %}" class="btn btn-sm btn-phoenix-primary me-4"><i class="fa-solid fa-user-tie me-1"></i> {% trans "Add New Staff" %}</a>
|
|
<a href="{% url 'group_list' %}" class="btn btn-sm btn-phoenix-success"><i class="fa-solid fa-user-group me-1"></i> {% trans "Manage Groups & Permissions" %}</a>
|
|
{% else %}
|
|
<div class="alert alert-outline-info d-flex align-items-center" role="alert">
|
|
<i class="fa-solid fa-circle-info fs-6"></i>
|
|
<p class="mb-0 flex-1">{{ _("No Active Subscription,please activate your subscription.") }}<a href="{% url 'pricing_page' %}" class="ms-3 text-body-primary fs-9">Manage Subscription</a></p>
|
|
<button class="btn-close" type="button" data-bs-dismiss="alert" aria-label="Close"></button>
|
|
</div>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="table-responsive scrollbar mx-n1 px-1 mt-3">
|
|
|
|
<table class="table align-items-center table-flush table-hover">
|
|
<thead>
|
|
<tr class="bg-body-highlight">
|
|
<th>{% trans 'name'|capfirst %}</th>
|
|
<th>{% trans 'email'|capfirst %}</th>
|
|
<th>{% trans 'phone number'|capfirst %}</th>
|
|
<th>{% trans 'role'|capfirst %}</th>
|
|
<th>{% trans 'actions'|capfirst %}</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for user in users %}
|
|
<tr>
|
|
<td class="align-middle white-space-nowrap ps-1">
|
|
<div>
|
|
<a class="fs-8 fw-bold" href="{% url 'user_detail' user.slug%}">{{ user.arabic_name }}</a>
|
|
|
|
</div>
|
|
</td>
|
|
<td class="align-middle white-space-nowrap align-items-center">{{ user.email }}</td>
|
|
<td class="align-middle white-space-nowrap align-items-center justify-content-center">{{ user.phone_number }}</td>
|
|
<td>
|
|
<span class="badge badge-sm bg-primary text-center"><i class="fa-solid fa-scroll"></i> {% trans user.staff_type|title %}</span>
|
|
</td>
|
|
|
|
<td class="align-middle white-space-nowrap">
|
|
<a class="btn btn-phoenix-success"
|
|
href="{% url 'user_detail' user.slug %}">
|
|
<i class="fa-solid fa-eye"></i>
|
|
{% trans 'view'|capfirst %}
|
|
</a>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<div class="d-flex justify-content-center">
|
|
{% if is_paginated %}
|
|
{% include 'partials/pagination.html' %}
|
|
{% endif %}
|
|
</div>
|
|
|
|
</div>
|
|
</section>
|
|
{% endblock %}
|
|
|