Jobs: the delete dialog and the chain-end states #176
Labels
No labels
adr
android
area/calendar
area/design-system
area/i18n
area/jobs
area/offline
area/server
area/testing
bug
ci
duplicate
enhancement
help wanted
invalid
notifications
question
reliability
security
severity/low
severity/medium
tracking
web
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
eagraiclainne/app#176
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of the jobs flow redesign. The design handoff (
design_handoff_jobs_flow, held outside the repo) is the source; the facts it depends on are repeated here so this issue stands alone.Delete is a hard delete with no undo, so it always asks, and the dialog names what survives it.
A plain job asks plainly. A job with sub-jobs counts them in the question and in the button (
Delete all 13), calls out how many are already ticked, and states what happens to the points: the earner keeps what they banked, and the linked reward returns to the rewards list. The cascade is real — sub-jobs go in the same transaction (internal/services/item/delete.go) — and unlinking the unclaimed rewards has now landed on the server, so the copy is true.Afterwards a notice rather than a snackbar, because there is no Undo to offer.
The chain-end states. Ticking a repeating job mints its successor, and that is the one other act that confirms first. The completed sheet then names the successor and offers it. If un-completion is attempted on a job that already spawned one the API refuses (
domain.ErrChainMovedOn); surface it asCan't reopen this — Tue 16 Sep took over. Open that one instead.A bare refusal strands the reader.A deleted repeating job ends its chain. A deleted completed job leaves its successor alone; they are separate records.
Update — the server side is done, in review
The dialog's second line ("the 22 points reward goes back to the rewards list")
was not true against the shipped server: delete left the reward pointing at a
dead row, and the eligibility filter then hid it for good.
That is fixed in PR #185 — unlinking joins the delete cascade for the job
and each cascaded sub-job, while claimed rewards keep their link as settled
history. Two integration specs cover it. The copy ships as written once that
merges; do not build this dialog against the old behaviour.
Two requirements added after #213 shipped
The job sheet went out to the family's cluster three times before it was right.
Seven visual defects, none caught by a suite: pickers that unfolded forms
instead of opening, three Save buttons on a commit-on-blur screen,
(optional)labels, a reward's name used as a field label, an unstyled add row, checkboxes
with a ghosted tick, and a create form with a browser spinner. Every one had to
be found by a person looking at a screen.
1. Screenshot goldens are part of this ticket
Record gallery (Playwright) and Roborazzi cases for every surface this ticket
builds or visibly changes, and treat them as a deliverable rather than a
follow-up. Three of #213's defects — the unstyled add row, the ghosted
checkboxes, the spinner in the create form — were pixel faults that a golden
would have caught before a deploy did.
#172deferred its goldens on the reasoning that later tickets would re-recordthem. That reasoning was sound then and is not now: the row grammar and the
pickers are settled, so an image recorded here stays valid.
Mechanics, from AGENTS.md: a new case rides in the same commit as the code
that adds it — a commit that adds a gallery or Roborazzi case without its image
is red on its own, because
check / webrunsnpm run test:screensandandroid / buildrunsverifyRoborazziDebug. A re-recorded existing casegoes in its own commit, so the reviewable diff stays code.
2. Check for leaked form styling before you finish
Every visual defect on #213 came from one place: the shipped app's form
fragments reused inside the new row grammar. They pass every test, because the
tests assert the pieces exist rather than that the screen reads right.
Before you call this done, grep the surfaces you touched and report what you
found and what you did about each:
<input>/OutlinedTextField/BasicTextFieldoutside the row andpicker components — a form field dropped into a list of rows
type="number", which renders browser spinner arrowsbtn,link-btn,btn-quietorTextButtonwhere a row or a quiet rowverb belongs — underlined links reading as broken text
(optional)in any label — §8 names that pattern as the form admitting itshould not have asked
Save changesandSave the pointslabel— that column is for afield's name (
Who,When,Worth), and a long title wraps in itIf your ticket is the first to land after this was written, add the check to
AGENTS.md beside the goldens rule, so it stops being a thing I remember to say.