first push

This commit is contained in:
2025-05-23 14:44:12 +08:00
commit abefd1b19b
817 changed files with 580289 additions and 0 deletions
+71
View File
@@ -0,0 +1,71 @@
{% extends 'layouts/main-layout.html' %}
{% block content %}
<div class="page-heading">
<div class="page-title">
<div class="row">
<div class="col-12 col-md-6 order-md-1 order-last">
<h3>Notifications</h3>
</div>
<div class="col-12 col-md-6 order-md-2 order-first">
<nav aria-label="breadcrumb" class="breadcrumb-header float-start float-lg-end">
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="/">Dashboard</a></li>
<li class="breadcrumb-item active" aria-current="page">Notifications</li>
</ol>
</nav>
</div>
</div>
</div>
<section class="section">
<div class="card">
<div class="card-body">
<div class="d-flex justify-content-end my-2 gap-2">
<input name="search_text" type="search" class='dataTable-input' autocomplete="off" placeholder='Search here...'
hx-get="{% url 'notifications:search' page_object.number %}" hx-trigger="keyup changed delay:500ms, search" hx-target="#search_result">
</div>
<table class="table table-hover" id="table1">
<thead>
<tr>
<th>Sl No.</th>
<th>Icon</th>
<th>Title</th>
<th>Notification Text</th>
<th>Datetime</th>
<th>Action</th>
</tr>
</thead>
{% if page_object %}
<tbody id="search_result">
{% for user_notification in page_object %}
<tr>
<td>{{page_object.start_index|add:forloop.counter0}}</td>
<td><i class='bi {{user_notification.notification.icon}} bi-sub fs-4 text-muted'></i></td>
<td>{{user_notification.notification.notification_title | title}}</td>
<td>{{user_notification.notification.notification_text}}</td>
<td>{{user_notification.notification.created_at}}</td>
<td>
<div class="btn-group btn-group-sm" role="group" aria-label="Basic example">
{% if user_notification.notification.link is not None %}
<a class="btn btn-success" href="{{user_notification.notification.link}}" class="btn btn-success" ><i class="bi bi-eye-fill"></i></a>
{% else %}
<button class="btn btn-danger" ><i class="bi bi-eye-fill"></i></button>
{% endif %}
</div>
</td>
<td>{{user_notification.last_login}}</td>
</tr>
{% endfor %}
</tbody>
{% else %}
<div class="alert alert-info" role="alert">
No record available!
</div>
{% endif %}
</table>
{% include 'commons/pagination.html' %}
</div>
</div>
</section>
</div>
{% endblock content%}