feat(backend): fix credit duplicates, support multi-role TV credits, fix collection upload
- Fix credit dedup key to people_id + cast_type (scoped to entry_id) - Detect aggregate_credits format via Array.isArray(c.roles) instead of is_tvseries flag - Join multiple roles/jobs with "; " instead of taking only the first - Add episode_count field to Credit model from total_episode_count - Increase character and job columns to VARCHAR(500) - Deselect existing collection posters/backdrops before inserting new upload - Updated docs-vault - Updated some agents files
This commit is contained in:
1 parent
260282a0e2
commit
ce01dc34fa
14 files changed
+293
-45
No files matched your search
+16
@@ -13,3 +13,19 @@
|
||||
- **EpisodePage**: Added `max-w-4xl` width constraint; changed breadcrumb from generic "Entry / Season" to "Title / Season x / Episode x"; fixed S## display to use `season.season_number` instead of `seasonId` (DB id)
|
||||
- **SettingsPage**: Added "Cleanup" card section with Scan/Delete buttons for orphan files and orphan media records, using existing maintenance API endpoints
|
||||
- Created `api/maintenance.ts` API client for maintenance endpoints
|
||||
|
||||
### Milestone 001.1
|
||||
|
||||
#### Backend Changes
|
||||
|
||||
- Fixed credit duplicate bug: changed unique key from `people_id + cast_type + tmdb_credit_id` to `people_id + cast_type` (scoped to entry_id) so TV series credits aren't re-inserted on every refresh
|
||||
- Fixed TV series character/job extraction: now detects aggregate_credits format via `Array.isArray(c.roles)` instead of relying on `is_tvseries` flag; joins all roles/jobs with `"; "` instead of only taking the first
|
||||
- Added `episode_count` field to Credit model, populated from `total_episode_count` in aggregate_credits response, tracked in change detection and `updateOnDuplicate`
|
||||
- Increased `character` and `job` column size from VARCHAR(100) to VARCHAR(500) to accommodate multiple roles joined by `"; "`
|
||||
- Fixed collection media upload: now deselects existing posters/backdrops (`isSelected = false`) before inserting new custom upload
|
||||
|
||||
#### Frontend Changes
|
||||
|
||||
- Created `MarkSeasonWatchedDialog` — dedicated dialog for marking a season as watched, replacing the old two-step EpisodeSeenEditDialog+ConfirmDialog flow
|
||||
- Added **Scatter Mode** toggle: distributes episodes across a date range (start → end) with an even spread, shows preview of days and max episodes/day
|
||||
- "Mark Season Watched" button is now always visible (not hidden when all episodes are watched)
|
||||
Reference in new issue
Block a user