fix: attendance admin — add user_name to records, fix Czech diacritics in table headers

- listAttendance() now maps users.first_name + last_name to user_name
- Fixed escaped Unicode in table headers (Zaměstnanec, Příchod, Poznámka)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
BOHA
2026-03-23 13:41:55 +01:00
parent c817e004b7
commit 2718a7b716
2 changed files with 5 additions and 3 deletions

View File

@@ -725,8 +725,10 @@ export async function listAttendance(params: ListAttendanceParams) {
...l,
project_name: projectNameMap.get(l.project_id) || `Projekt #${l.project_id}`,
}));
const u = rec.users;
return {
...rec,
user_name: u ? `${u.first_name} ${u.last_name}`.trim() : '',
project_name: rec.project_id ? (projectNameMap.get(rec.project_id) || null) : null,
project_logs: logs,
};