Refactor: Simplify case directory structure

The distinction between `open/` and `done/` directories for cases has
been removed.
All cases for a user now reside directly under the user's directory
(e.g., `<data_path>/<slug>/<case_id>/`).

This simplifies path management and eliminates redundant directory
traversals.

Key changes include:
- Removed `open/` and `done/` subdirectories in path resolution.
- Introduced a `paths::case_dir` function as a single source of truth
  for case directory layout.
- Updated various modules (`recovery`, `auth`, `routes`, `transcribe`,
  `tests`) to use the new path structure.
- Adjusted templates to reflect the simplified case status
  representation.
This commit is contained in:
2026-04-15 22:15:13 +02:00
parent 70eed20909
commit 11eb645f3f
17 changed files with 190 additions and 324 deletions
+2 -2
View File
@@ -26,8 +26,8 @@ body { font-family: sans-serif; max-width: 900px; margin: 2em auto; padding: 0 1
<p>No cases found.</p>
{% else %}
{% for case in cases %}
<div class="case status-{{ case.status }}">
<h2>{{ case.user_slug }} — {{ case.case_id_short }} ({{ case.status }})</h2>
<div class="case {% if case.has_document %}status-done{% else %}status-open{% endif %}">
<h2>{{ case.user_slug }} — {{ case.case_id_short }} ({% if case.has_document %}analyzed{% else %}in progress{% endif %})</h2>
{% match case.oneliner %}
{% when Some with (t) %}
<div class="oneliner">{{ t }}</div>