diff --git a/templates/admin/dashboard.html b/templates/admin/dashboard.html index 093e194..9cab112 100644 --- a/templates/admin/dashboard.html +++ b/templates/admin/dashboard.html @@ -3,8 +3,9 @@ {% load app_filters %} {% block extrahead %} {{ block.super }} - + + @@ -33,123 +34,67 @@ }); } }); - - // Add CSRF token to all AJAX requests - function getCookie(name) { - let cookieValue = null; - if (document.cookie && document.cookie !== '') { - const cookies = document.cookie.split(';'); - for (let i = 0; i < cookies.length; i++) { - const cookie = cookies[i].trim(); - if (cookie.substring(0, name.length + 1) === (name + '=')) { - cookieValue = decodeURIComponent(cookie.substring(name.length + 1)); - break; - } - } - } - return cookieValue; - } - - // Set up CSRF token for AJAX requests - const csrftoken = getCookie('csrftoken'); - - // Add CSRF token to all AJAX requests - $(document).ready(function() { - $.ajaxSetup({ - beforeSend: function(xhr, settings) { - if (!/^(GET|HEAD|OPTIONS|TRACE)$/i.test(settings.type) && !this.crossDomain) { - xhr.setRequestHeader("X-CSRFToken", csrftoken); - } - } - }); - }); - - // Update all form submissions to include CSRF token - document.addEventListener('DOMContentLoaded', function() { - // Add CSRF token to fetch requests - window.fetch = new Proxy(window.fetch, { - apply: function(fetch, that, args) { - if (args.length > 0 && typeof args[0] === 'object' && args[0].method !== 'GET') { - if (args[0].headers) { - args[0].headers['X-CSRFToken'] = csrftoken; - } else { - args[0].headers = { 'X-CSRFToken': csrftoken }; - } - } - return fetch.apply(that, args); - } - }); - }); {% endblock %} {% block extrastyle %} {{ block.super }} {% endblock %} @@ -753,21 +468,20 @@
Student Management Dashboard
- - +| Teacher | -Student Rating | -Parent Rating | -Total Feedbacks | -|||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
-
- {% if teacher.image %}
-
-
-
- {% endif %}
-
- {{ teacher.name }}- {{ teacher.designation }} ++ Top Rated Teachers ++
+
+
+ {{ teacher.total_feedbacks }}
+ |
+ | |||||||||||||
| + No teacher ratings available + | +||||||||||||||
| Date | Time | @@ -1256,61 +961,47 @@{{ meeting.duration }} minutes | {% if meeting.is_online %} - - Online - {% if meeting.meeting_link %} - - - {% endif %} - + Online + {% if meeting.meeting_link %} + + + {% endif %} {% else %} - - In-person - + In-person {% endif %} | - - {% if meeting.status == 'scheduled' %} - Scheduled - {% elif meeting.status == 'completed' %} - Completed - {% elif meeting.status == 'cancelled' %} - Cancelled - {% else %} - Rescheduled - {% endif %} + + {{ meeting.get_status_display }} |
-
- {% if meeting.status == 'scheduled' %}
-
+ {% if meeting.status == 'scheduled' %}
+ |
|---|
Scheduling meeting...
-Loading notes...
+Loading agenda...
Cancelling meeting...
-Rescheduling meeting...
-