Убрать служебную сводку ДПО из карточки #85
No files matched your search
@@ -1,5 +1,9 @@
|
||||
# Changelog
|
||||
|
||||
## 2.4.1
|
||||
|
||||
- В карточке сотрудника убрана служебная сводка подтверждения ДПО. Сохранённые курсы доступны в редакторе списка.
|
||||
|
||||
## 2.4.0
|
||||
|
||||
- Любой вошедший пользователь может подтвердить список ДПО в карточке сотрудника. Справочник и XLSX учитывают подтверждённое количество, включая ноль. Фильтр повышения квалификации учитывает вид и год подтверждённых курсов.
|
||||
|
||||
@@ -11,18 +11,9 @@
|
||||
</fieldset>
|
||||
{% endmacro %}
|
||||
<section class="panel" id="unresolved-dpo" tabindex="-1">
|
||||
<h2 class="panel__title">Проверка ДПО</h2>
|
||||
{% if review %}
|
||||
<p>Подтверждено курсов: <strong>{{ review.courses | length }}</strong> · {{ review.updated_by }} · {{ review.updated_at | admin_datetime }}</p>
|
||||
{% if review.courses %}<ol>{% for course in review.courses %}
|
||||
<li>{{ course.title }} · {{ kinds[course.kind] }}{% if course.year %} · {{ course.year }}{% endif %}{% if course.evidence %} · {{ course.evidence }}{% endif %}</li>
|
||||
{% endfor %}</ol>{% endif %}
|
||||
{% endif %}
|
||||
{% if employee_view.dpo_uncertain %}
|
||||
<h3>Количество ДПО требует проверки</h3>
|
||||
{% if review %}<p>Сведения о ДПО изменились. В справочнике учтён последний подтверждённый список.</p>{% endif %}
|
||||
{% endif %}
|
||||
{% if employee_view.dpo_uncertain or review %}
|
||||
{% for section in employee_view.sections if section.type == 'additional_education' %}
|
||||
<h4>{{ section.title }} · сведения профиля</h4>
|
||||
{% if not section.list_items %}<p>В разделе ДПО не удалось выделить отдельные записи.</p>{% endif %}
|
||||
|
||||
+3
-3
@@ -1,3 +1,3 @@
|
||||
APP_VERSION = "2.4.0"
|
||||
FRONTEND_VERSION = "2.4.0"
|
||||
BACKEND_VERSION = "2.4.0"
|
||||
APP_VERSION = "2.4.1"
|
||||
FRONTEND_VERSION = "2.4.1"
|
||||
BACKEND_VERSION = "2.4.1"
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = "miem-workers"
|
||||
version = "2.4.0"
|
||||
version = "2.4.1"
|
||||
description = "MIEM employees parser, admin API, and web admin"
|
||||
requires-python = ">=3.11"
|
||||
dependencies = [
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ def test_health_returns_versions():
|
||||
response = TestClient(app).get("/api/health")
|
||||
|
||||
assert response.status_code == 200
|
||||
assert response.json()["backend_version"] == "2.4.0"
|
||||
assert response.json()["backend_version"] == "2.4.1"
|
||||
|
||||
|
||||
def test_api_employees_and_stats_require_admin_session():
|
||||
|
||||
@@ -230,7 +230,7 @@ def test_public_page_data_minimization_and_safe_links(db_session, export):
|
||||
assert "javascript:" not in fragment.text and "private@example.org" not in fragment.text
|
||||
assert "javascript:" not in response.text and "private@example.org" not in response.text
|
||||
assert "/admin/employees/" not in response.text and "/admin/logout" not in response.text
|
||||
assert "Backend 2.4.0 · Frontend 2.4.0" in response.text
|
||||
assert "Backend 2.4.1 · Frontend 2.4.1" in response.text
|
||||
assert "Вход в систему" in response.text
|
||||
assert client.get("/admin/directory", follow_redirects=False).status_code in (302, 303, 401, 403)
|
||||
assert "Сотрудники не найдены" in client.get("/admin/council?q=missing").text
|
||||
|
||||
@@ -453,6 +453,10 @@ def test_reader_confirms_dpo_and_changed_sources_require_review(accounts):
|
||||
assert client.post(url, json=payload).status_code == 403
|
||||
assert client.post(url, json=payload, headers=headers).status_code == 200
|
||||
assert client.post(url, json=payload, headers=headers).status_code == 409
|
||||
panel = BeautifulSoup(client.get(url[:-4]).text, "html.parser").select_one("#unresolved-dpo")
|
||||
assert "Подтверждено курсов" not in panel.get_text()
|
||||
assert panel.select_one("ol") is None
|
||||
assert panel.select_one("[data-rows] input[name=title]")["value"] == "Инженерная практика"
|
||||
assert not employee_detail_payload(employee)["dpo_uncertain"]
|
||||
result = list_employees_page(db, training_since_year=2025)["employees"]
|
||||
assert [row["dpo_count"] for row in result] == [1]
|
||||
|
||||
Reference in new issue
Block a user