rework issue system

This commit is contained in:
Matthias Hochmeister
2026-03-24 15:30:24 +01:00
parent 65994286b2
commit d8d2730547
9 changed files with 316 additions and 186 deletions

View File

@@ -525,7 +525,7 @@ class EquipmentService {
async getStatusHistory(equipmentId: string) {
try {
const result = await pool.query(
`SELECT h.*, u.display_name AS geaendert_von_name
`SELECT h.*, COALESCE(u.name, u.preferred_username, u.email) AS geaendert_von_name
FROM ausruestung_status_historie h
LEFT JOIN users u ON u.id = h.geaendert_von
WHERE h.ausruestung_id = $1