Admin: a recording's "kept until" date, the tables on a phone, and binned campaigns (#872) #1021
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/872-admin-kept-until-phone-tables"
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?
Closes #872, and folds in a leftover: Admin → Campaigns never asked for binned campaigns and had no test.
1. "Kept until" on the recordings table (ADMIN-6)
retention.audio_expires_at(session, policy)is the date the nightly sweep acts on, andaudio_window_catchesnow reads it, so the table's date and the sweep's decision are one piece of arithmetic. The refactor is behaviour-preserving: the same guards in the same order, andanchor + days < nowforanchor < now - days. Tests assert the sweep catches a recording one second after the date and not one second before.GET /api/admin/recordingsrows gainaudio_expires_at,audio_retention_mode,audio_retention_days,audio_retention_source(campaign,instanceorcap) andcontent_approved.2. The Admin tables at phone width
Audit, Users, Campaigns and the recordings table each have a minimum width and scroll sideways inside their own named, focusable region; the page never scrolls sideways. Dates and short cells stay on one line; prose wraps. Minimums are tuned so nothing scrolls at 1024.
3. Admin → Campaigns
retention.trash_purge_at).days/forever; the server's values areretain_days,retain_indefinitely,trash_after_approval. It now reads "Audio 30 days · Transcripts 6 months", "Audio for good", "Audio binned once approved", "Transcripts for good", and "The instance's" with no override.AdminCampaigns.test.jsxis new: the list, archived, binned with and without a date, every retention mode, hand-on, empty, failed load.Also fixed
A failed recording's line doubled its punctuation when the error ended in a full stop (
…did not answer.”.).Checked
coverage/lane*.pypasses. Catalogue rows IS-470 and IS-471.docs/API.mdupdated.Noted, not changed
"Hand it on…" is offered on a binned and on an archived campaign, as the drawing has it. On a phone the recordings table's status and action are reached by scrolling the region right.
🤖 Generated with Claude Code