feat(backend): customer display looks on the media library, one per display (platform-v2 step 5.3)

- display_looks (Alembic 0028): named idle screens, one default; config is
  the 3.4 design with pictures as media library ids. 0028 turns the setting
  customer_display.idle into the look "Main" and moves its data/display_media
  pictures into the library (the old folder stays on disk).
- A display shows the look in its device config `look` (ref ConfigField,
  choices_from "display_looks", validated in device_config) or the default.
- /api/display/looks (GET also for core.devices.manage), POST, PUT,
  POST /{id}/default, DELETE (not the default; its displays go back to it);
  /api/display/displays and PUT /displays/{id}/look. A change sends
  display.settings only to the displays showing that look.
- /api/display/settings, /api/display/media* and their error codes are gone;
  GET /api/display/state keeps its shape (logo card size, image/slides full).
- Looks register their media usage (a picture in a look can't be deleted).
- tests: test_customer_display.py (7, incl. two displays two slideshows and
  the 0028 data move); 501 passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-17 17:50:51 +02:00
co-authored by Claude Opus 5.5
parent 87dff573df
commit 27d7bbb976
13 changed files with 495 additions and 173 deletions
+4 -4
View File
@@ -122,10 +122,10 @@
"table_busy": "Αυτό το τραπέζι έχει ήδη ανοιχτή παραγγελία. Διαλέξτε άλλο τραπέζι ή κλείστε πρώτα εκείνη την παραγγελία."
},
"display": {
"media_unknown": "Η εικόνα {{name}} δεν βρέθηκε.",
"media_type": "Ανεβάστε εικόνα JPG, PNG, WebP ή GIF.",
"media_too_big": "Η εικόνα είναι πολύ μεγάλη (έως {{max_mb}} MB).",
"qr_url_missing": "Γράψτε τον σύνδεσμο που ανοίγει ο QR κωδικός."
"qr_url_missing": "Γράψτε τον σύνδεσμο που ανοίγει ο QR κωδικός.",
"look_unknown": "Η εμφάνιση {{look_id}} δεν βρέθηκε.",
"look_default": "Η προεπιλεγμένη εμφάνιση δεν διαγράφεται. Ορίστε πρώτα άλλη ως προεπιλογή.",
"not_a_display": "Η συσκευή {{device_id}} δεν είναι οθόνη πελάτη."
},
"media": {
"not_found": "Το αρχείο {{media_id}} δεν υπάρχει στη βιβλιοθήκη πολυμέσων.",
+7
View File
@@ -87,6 +87,13 @@
},
"permissions": {
"manage": "Ρύθμιση της οθόνης πελάτη (οθόνη αναμονής, εικόνες)"
},
"config": {
"look": {
"label": "Οθόνη αναμονής",
"hint": "Ποια εμφάνιση δείχνει ανάμεσα στις πωλήσεις (Ρυθμίσεις → Οθόνη πελάτη).",
"none": "Η προεπιλεγμένη εμφάνιση"
}
}
},
"expenses": {