From c83b878be676657f6a4fe234c496c83465974420 Mon Sep 17 00:00:00 2001 From: Faheed Date: Sun, 7 Dec 2025 17:20:08 +0300 Subject: [PATCH] small ifx --- recruitment/views.py | 1 + templates/includes/easy_logs.html | 28 ++++++++++++++-------------- 2 files changed, 15 insertions(+), 14 deletions(-) diff --git a/recruitment/views.py b/recruitment/views.py index f856e7c..2ea9ccb 100644 --- a/recruitment/views.py +++ b/recruitment/views.py @@ -163,6 +163,7 @@ logger = logging.getLogger(__name__) User = get_user_model() @login_required +@superuser_required def settings(request): return render(request,'user/settings.html') diff --git a/templates/includes/easy_logs.html b/templates/includes/easy_logs.html index aff3890..63ab363 100644 --- a/templates/includes/easy_logs.html +++ b/templates/includes/easy_logs.html @@ -93,9 +93,9 @@ } /* ---------------------------------------------------- */ - /* 5. BADGE VISIBILITY FIXES (Guaranteed Colors) */ + /* 5. badges VISIBILITY FIXES (Guaranteed Colors) */ /* ---------------------------------------------------- */ - .badge { + .badges { font-weight: 600; line-height: 1.4; padding: 0.4em 0.6em; @@ -106,26 +106,26 @@ position: relative; } - /* Dark Badges (CRUD Create/Delete & Login/Logout Type) - Use light text */ - .badge-crud-create { + /* Dark badgess (CRUD Create/Delete & Login/Logout Type) - Use light text */ + .badges-crud-create { background-color: var(--color-success) !important; color: var(--color-text-on-dark) !important; } - .badge-crud-delete { + .badges-crud-delete { background-color: var(--color-danger) !important; color: var(--color-text-on-dark) !important; } - .badge-login-status { + .badges-login-status { background-color: var(--color-primary-dark) !important; color: var(--color-text-on-dark) !important; } - /* Light Badges (CRUD Update & Request Method) - Use dark text */ - .badge-crud-update { + /* Light badgess (CRUD Update & Request Method) - Use dark text */ + .badges-crud-update { background-color: var(--color-warning) !important; color: var(--color-text-dark) !important; } - .badge-request-method { + .badges-request-method { background-color: var(--color-info) !important; color: var(--color-text-dark) !important; } @@ -228,9 +228,9 @@ {{ log.user.email|default:"N/A" }} + {% if log.event_type == 1 %}badges-crud-create + {% elif log.event_type == 2 %}badges-crud-update + {% else %}badges-crud-delete{% endif %}"> {% if log.event_type == 1 %}{% trans "CREATE" %} {% elif log.event_type == 2 %}{% trans "UPDATE" %} {% else %}{% trans "DELETE" %}{% endif %} @@ -256,7 +256,7 @@ {% endwith %} -