From e89b66080b9edf6816b69183f8376e1ce83425a1 Mon Sep 17 00:00:00 2001 From: Macbook Date: Tue, 23 Dec 2025 01:38:19 +0300 Subject: [PATCH] beta 2.3 --- app.db | Bin 61440 -> 61440 bytes medods_handler.py | 1 + static/css/birthdate.css | 2 +- static/js/birthdate.js | 11 +++++------ templates/birthdate.html | 7 +++---- 5 files changed, 10 insertions(+), 11 deletions(-) diff --git a/app.db b/app.db index fca998c48a3fd83a9ac6cfebccc3530f49a5c6a1..b30ed5859bff9670f88cf4c8fc770a0d06d99a49 100644 GIT binary patch delta 70 zcmZp8z})bFd4e?Ktcfzttg{&O+B7$&6wcQ+Hwp+Y^{)yp4fiPx3o-V}D6;e~Ff|XU aiuX$@4Kp>&&CDq%^R4nXGIm|GAOHY#gc#re delta 70 zcmZp8z})bFd4e?K%!xA2tTP$(x bool: continue userDict = { "id": int(user["id"]), + "enabled": user["status"] == "active", "name": f"{user['surname']} {user['name']} {user['secondName']}", "short_name": f"{user['surname']} {user['name'][:1]}. {user['secondName'][:1]}.", "sex": user["sex"], diff --git a/static/css/birthdate.css b/static/css/birthdate.css index 098b800..eed018f 100644 --- a/static/css/birthdate.css +++ b/static/css/birthdate.css @@ -27,7 +27,7 @@ /* Таблица сотрудников */ .table-responsive { - max-height: 600px; + max-height: 800px; overflow-y: auto; } diff --git a/static/js/birthdate.js b/static/js/birthdate.js index 568651a..3925f19 100644 --- a/static/js/birthdate.js +++ b/static/js/birthdate.js @@ -58,6 +58,7 @@ function renderUsersTable() { `; return; } + document.getElementById('usersCount').textContent = usersData.length; // Сортируем по дате рождения (месяц и день) usersData.sort((a, b) => { @@ -85,7 +86,8 @@ function renderUsersTable() { const fullDate = birthdate.toLocaleDateString('ru-RU'); // Форматируем месяц и день (двузначные) - const monthStr = month.toString().padStart(2, '0'); + const monthNames = ['января', 'февраля', 'марта', 'апреля', 'мая', 'июня', 'июля', 'августа', 'сентября', 'октября', 'ноября', 'декабря']; + const monthStr = monthNames[month - 1]; const dayStr = day.toString().padStart(2, '0'); // Определяем пол @@ -119,7 +121,7 @@ function renderUsersTable() {
- ${monthStr}.${dayStr} + ${dayStr} ${monthStr}
@@ -132,10 +134,7 @@ function renderUsersTable() { ${sexBadge} ${specialtiesHtml} - ${enabledStatus} - -
${dataStatus}
- + ${enabledStatus} ${dataStatus} `; }); diff --git a/templates/birthdate.html b/templates/birthdate.html index ac4746e..6fa7905 100644 --- a/templates/birthdate.html +++ b/templates/birthdate.html @@ -23,7 +23,7 @@
-
Сотрудники
+
Сотрудники (0)
@@ -41,7 +41,6 @@ Пол Специальности Статус - Данные @@ -61,13 +60,13 @@