feat(admin): material column + inline material manager in the Sessions view
- Sessions table gains a Material column (uploaded pill with the clean filename in its tooltip, dash when none) - Expanded session row: shared MaterialPanel (open / download / delete with confirm) plus immediate upload/replace via MaterialUploadRow - Schedule session modal refactored onto the same MaterialPanel; its upload keeps the uploads-on-Save behavior - sessions-view e2e: new test pins the pill, panel buttons, clean filename, unlock hint and replace control
This commit is contained in:
1 parent
d3f083a99e
commit
076904ffd3
6 files changed
+210
-77
No files matched your search
@@ -19,7 +19,7 @@ It runs on **port 3001** (Vite dev) or as the `convivo-admin` Docker container
|
||||
| **Registrations** | Per active event: list (contact, type, **QR token**, checked_in, points). Change type (enforces the sponsor rule — a failed sponsor change opens an **in-place sponsor lookup** popup), mark checked-in, **view the QR token** (final — no reset), and **preview the attendee's badge** (renders the event's badge layout with that row's own name / ticket type / QR token / company), plus a **Print** button that queues the badge on the print station ([../backend/printing.md](../backend/printing.md)). When the event has **no badge configured**, the Badge button stays visible but **grayed out**, and hovering it shows a tooltip explaining a badge must be designed first. A general search matches **first name, last name, email address or type**; the **Type**, **QR token** (ticket) and **Checked in** columns each have an Excel-style **multi-select filter** with live counts. The **checked-in toggle is per-row and optimistic**: it patches that one row (and its points) in place — **no list reload**, so rows never jump or vanish mid-edit (the list is sorted by points) — while a small "Saving…" pulse marks the busy row and only that checkbox is disabled; other rows stay live and a second row can be toggled concurrently. A rejected write rolls the row back to the server's values. Changing the type behaves the same way. The toggle is what grants front-desk eligibility from the console (see [../backend/rpcs.md](../backend/rpcs.md)). Points moved here from Contacts: each point-earning row of the **active** event carries a **Points** button (`adjust_points` always targets the active event's pass, so on other events the button is disabled with an explanatory tooltip), opening a modal that applies the delta, patches the row in place — no reload, no reordering — and lets the silent refresher settle the truth. Rows excluded from points (the `_points_eligible` mirror: type staff, Admin contact, `@appe.at`) show the "no points" marker and no button. |
|
||||
| **Sponsors** | List (paid only visible to attendees; admin sees all). Add/edit (type, name, email, phone, paid, amount, **contact search-and-pick**). |
|
||||
| **Schedule** | Slots (with a **type optionset** — `Session` / `Service Session`) + sessions (with speakers 1:N via a **multi-select search dropdown**, material upload with a **submitted / not submitted** state and `average_feedback`), plus an admin-only **Delete current schedule** action for the active event. |
|
||||
| **Sessions** | Everything about the **active event's sessions** in one place (nav sits between Schedule and Activity): one row per session with its slot date/time, room / level / area, **speakers**, **check-in count** (with capacity when set), **average rating and response count**, and whether an AI summary is stored, **out of date**, or impossible. Click a row to expand it: description, the full **speaker list**, the **roster of who checked in** (with time and which staff member scanned them), and the stored **AI summary**. A **search** box matches title, room, level, area or speaker, and the **attendee filter** answers "which sessions did this person actually attend?" — the list narrows to those sessions, the header states the count, and the expanded roster highlights that person. **Generate AI Feedback Summary** (see below) summarises every session with feedback in one click. Data comes from `sessions` ⨝ `slots` ⨝ `session_speakers` ⨝ `checkins` ⨝ `feedback`, joined in the client so the numbers match the other views exactly and no new RLS policy is needed. |
|
||||
| **Sessions** | Everything about the **active event's sessions** in one place (nav sits between Schedule and Activity): one row per session with its slot date/time, room / level / area, **speakers**, **material** (an `uploaded` pill — see [Session material](#session-material)), **check-in count** (with capacity when set), **average rating and response count**, and whether an AI summary is stored, **out of date**, or impossible. Click a row to expand it: description, the full **speaker list**, the **roster of who checked in** (with time and which staff member scanned them), the stored **AI summary**, and the **material manager** (open / download / delete / upload on behalf of the speaker). A **search** box matches title, room, level, area or speaker, and the **attendee filter** answers "which sessions did this person actually attend?" — the list narrows to those sessions, the header states the count, and the expanded roster highlights that person. **Generate AI Feedback Summary** (see below) summarises every session with feedback in one click. Data comes from `sessions` ⨝ `slots` ⨝ `session_speakers` ⨝ `checkins` ⨝ `feedback`, joined in the client so the numbers match the other views exactly and no new RLS policy is needed. |
|
||||
| **Activity** | Tables of check-ins, connections, and feedback (per active event; staff auto-pairings — `connections.auto` — are hidden here too), with manual **Generate AI Summary** controls for the event and individual sessions. |
|
||||
| **Raffle** | Draws eligible attendees one at a time for the active event. Configure the number of picks (default 5), then **Spin** a roulette that decelerates onto a server-chosen winner; repeat until the pick count is reached. Excludes staff/Admin and the leaderboard top 3, and no one can win twice in a run. **New run** clears the current winners. See [../backend/rpcs.md#raffle](../backend/rpcs.md#raffle). |
|
||||
| **Badges** | A **per-event WYSIWYG badge / PDF layout editor** (modelled on pretix's PDF Editor). Pick the event, then design one or more named **layouts** (a **Default** per event, switchable / creatable / deletable). Add **text boxes**, **QR codes** and **images** to a millimetre canvas; drag to move, use the 8 resize handles + rotation handle, **Shift-click to multi-select**, and **press `Del`** to remove. While dragging, **PowerPoint-style smart guides** appear — dashed alignment lines (edges / centres, page and neighbouring items) plus equal-spacing lines — and the element **snaps** to them. A **Word-style align** toolbar (left / center / right, top / middle / bottom) plus **PowerPoint-style** object alignment — align to the **page** or to the **selection**, and **distribute** horizontally / vertically — with the same controls in the properties panel. Text binds to attendee fields (name, email, ticket type, QR token, event name, **company / organizer**, or static) with font, size, line-height, colour, bold/italic, a labelled **Align text in box** section (horizontal left / center / right and vertical top / middle / bottom, inside the element's own frame) and case transform; QR binds to the token / check-in URL / email / name / static. **Undo/redo** (`Ctrl`+`Z` / `Ctrl`+`Y`, also `Ctrl`+`Shift`+`Z`), a **Preview** mode (no handles), a **JSON** view of the layout, and **Save**. Previewed against a real sample registration. See [../backend/rpcs.md#badge-editor](../backend/rpcs.md#badge-editor). |
|
||||
@@ -303,6 +303,12 @@ the attendee time-lock):
|
||||
directly), the previous object is deleted, and a failed DB update rolls the
|
||||
fresh upload back. New sessions upload right after creation.
|
||||
|
||||
The **Sessions** view carries the same manager: a **Material** column shows an
|
||||
`uploaded` pill (clean filename in its tooltip) or a dash, and the expanded
|
||||
row exposes **Open / Download / Delete** plus an **immediate upload/replace**
|
||||
input — handy for answering "my file is missing" tickets without hunting the
|
||||
schedule grid. Both surfaces share `components/MaterialPanel.tsx`.
|
||||
|
||||
### Feedback AI Summaries
|
||||
|
||||
Configure the complete OpenAI-compatible HTTPS endpoint, model and optional key
|
||||
|
||||
Reference in new issue
Block a user