Scenes become real objects: campaign-wide, reusable across sessions, buildable before they have cards (the Quest Board half of #689) #1347

Closed
opened 2026-11-06 02:02:59 +00:00 by claude-bot · 2 comments
Collaborator

Split from #689 (owner, 2026-11-06). This issue covers everything in #689 that doesn't need Foundry, for v4.8.0. Pairing a scene with a Foundry map stays in #689 (v5.1), and attaches to the field this issue leaves for it.

Today

There is no scene table. shelf_cards.scene is free text, and the scene bar is worked out from the distinct values on the board (SessionShelf.jsx). So a scene can't be empty, renamed or deleted, and doesn't exist outside the session whose cards carry the name.

Change

  • A scenes table, scoped to the campaign: a name, a position for ordering, created and updated timestamps, soft delete in line with the rest of the app, and a nullable foundry_map_ref left empty for #689.
  • shelf_cards.scene_id (FK, SET NULL) replaces the text column, as expand then contract: keep the text column unmapped until a later contract migration, as #330 did.
  • An empty scene is allowed: build "The docks" in Prep, then fill it.
  • Reuse: a campaign's scenes can be chosen in any session. Cards stay per-session; the scene is shared.
  • Rename and delete are real operations. Deleting a scene doesn't delete its cards; they become unsorted.
  • Migration: each distinct (session, scene) string becomes a scene row. Identical names in different sessions of one campaign are the hard case. Recommended: separate rows, plus a GM prompt to merge ("Docks" appears in 3 sessions; make it one scene?). The owner decides this before build.

Must not regress (#235's rules, which are why the tag won)

  • Filtering hides cards and never moves them; stored x/y is untouched across a swap.
  • Number keys 1–9 and the stage's previous/next walk the visible scene.
  • A staged card stays staged across a swap.
  • A Ctrl-K hit from another scene swaps the board to that scene.

Where it shows

  • Table mode's scene bar (TABLE-1): switch scenes.
  • Prep (PREP-1): build, rename, reorder and delete scenes, and add cards to them.

Both were drawn with scenes as real objects in the redesign (lane 4, #659). Check the drawings, and draw anything missing before building.

Also

  • Export and import carry scenes.
  • An existing campaign keeps its pins.
  • Tests for each item under "Must not regress", plus the migration, including the duplicate-name case.
  • A changelog fragment, and a CATALOGUE row if a surface is new.
Split from #689 (owner, 2026-11-06). This issue covers everything in #689 that doesn't need Foundry, for v4.8.0. Pairing a scene with a Foundry map stays in #689 (v5.1), and attaches to the field this issue leaves for it. ## Today There is no scene table. `shelf_cards.scene` is free text, and the scene bar is worked out from the distinct values on the board (`SessionShelf.jsx`). So a scene can't be empty, renamed or deleted, and doesn't exist outside the session whose cards carry the name. ## Change - **A `scenes` table, scoped to the campaign:** a name, a position for ordering, created and updated timestamps, soft delete in line with the rest of the app, and a nullable `foundry_map_ref` left empty for #689. - **`shelf_cards.scene_id`** (FK, SET NULL) replaces the text column, as expand then contract: keep the text column unmapped until a later contract migration, as #330 did. - **An empty scene is allowed:** build "The docks" in Prep, then fill it. - **Reuse:** a campaign's scenes can be chosen in any session. Cards stay per-session; the scene is shared. - **Rename and delete** are real operations. Deleting a scene doesn't delete its cards; they become unsorted. - **Migration:** each distinct `(session, scene)` string becomes a scene row. Identical names in different sessions of one campaign are the hard case. Recommended: separate rows, plus a GM prompt to merge ("Docks" appears in 3 sessions; make it one scene?). The owner decides this before build. ## Must not regress (#235's rules, which are why the tag won) - Filtering hides cards and never moves them; stored x/y is untouched across a swap. - Number keys 1–9 and the stage's previous/next walk the visible scene. - A staged card stays staged across a swap. - A Ctrl-K hit from another scene swaps the board to that scene. ## Where it shows - **Table mode's scene bar (`TABLE-1`):** switch scenes. - **Prep (`PREP-1`):** build, rename, reorder and delete scenes, and add cards to them. Both were drawn with scenes as real objects in the redesign (lane 4, #659). Check the drawings, and draw anything missing before building. ## Also - Export and import carry scenes. - An existing campaign keeps its pins. - Tests for each item under "Must not regress", plus the migration, including the duplicate-name case. - A changelog fragment, and a CATALOGUE row if a surface is new.
Author
Collaborator

Decided (owner, 2026-11-06, Q232; D332): same-named scenes from different sessions stay separate scenes. Prep shows the GM a one-time prompt ("Docks" is in 3 sessions; make it one scene?) and never asks again. Cards never move either way.

**Decided (owner, 2026-11-06, Q232; D332):** same-named scenes from different sessions stay **separate** scenes. Prep shows the GM a one-time prompt ("Docks" is in 3 sessions; make it one scene?) and never asks again. Cards never move either way.
Author
Collaborator

Closing: already built and shipped, in 4.5.0. I wrote this issue from #689's original description without checking the code. That was my mistake.

The Quest Board half of #689 was built in the redesign (lane 5 PR 1, #731, commit 7abfb6a0; first tagged in v4.5.0-rc1):

  • scenes table per campaign, with sort and soft delete (app/models/scene.py, migration b2c4d6e8f0a1);
  • shelf_cards.scene_id and shelf_pins.scene_id (SET NULL);
  • the text column dropped later (e5f7a9b1c3d4);
  • the API in routers/scenes.py;
  • Table mode's scene bar and scenes panel (D33, lane 4), and Prep's scene groups, empty scenes, rename, delete with Undo and "File it" (D43, lane 5).

Same-named scenes were settled at the time (D114): the 4.5.0 migration merged them automatically, ignoring case and spacing, because a migration can't ask anyone. So D332 (today's answer, recorded in #1348) describes a migration that already ran differently on every install. It's marked superseded in a docs follow-up.

The Foundry map column is still deliberately absent (D113). It belongs to #689, in v5.1.

**Closing: already built and shipped, in 4.5.0.** I wrote this issue from #689's original description without checking the code. That was my mistake. The Quest Board half of #689 was built in the redesign (lane 5 PR 1, #731, commit `7abfb6a0`; first tagged in `v4.5.0-rc1`): - `scenes` table per campaign, with `sort` and soft delete (`app/models/scene.py`, migration `b2c4d6e8f0a1`); - `shelf_cards.scene_id` and `shelf_pins.scene_id` (SET NULL); - the text column dropped later (`e5f7a9b1c3d4`); - the API in `routers/scenes.py`; - Table mode's scene bar and scenes panel (D33, lane 4), and Prep's scene groups, empty scenes, rename, delete with Undo and "File it" (D43, lane 5). **Same-named scenes were settled at the time (D114):** the 4.5.0 migration merged them automatically, ignoring case and spacing, because a migration can't ask anyone. So D332 (today's answer, recorded in #1348) describes a migration that already ran differently on every install. It's marked superseded in a docs follow-up. The Foundry map column is still deliberately absent (D113). It belongs to #689, in v5.1.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
rbrooks/Quest-Board#1347
No description provided.