Read-only list endpoints so the ChicoryTV SPA schedule-editor and channel pickers (#86, #89) can populate their dropdowns:
GET /api/filler-presets
GET /api/watermarks
GET /api/graphics-elements
Each returns a lightweight (Id, Name) response model — exactly what the Blazor pickers consume — instead of the full 15+-field ViewModels, keeping the OpenAPI surface clean. Graphics elements reuse ProjectToViewModel so API names match the Blazor display names, and reproduce the existing ordering rule (named elements before file-name-only ones).
Built on the salvaged WIP commit: reviewed against conventions, added route Name= attributes, handler tests (InMemoryTvContext harness: seeding, DTO projection, empty-DB, graphics ordering), and OpenAPI regen. TZ=UTC dotnet test ErsatzTV.Tests → 270 passed.
Review
Adversarial review of the full diff vs main: no blockers/majors.
MINOR (parity by design): filler-preset and watermark lists return DB order (no OrderBy(Name)), same as the Blazor handlers; SPA should client-sort if it cares.
The optional languages-list endpoint from the issue is deferred to a follow-up.
No model/migration changes; migrations job unaffected.
Fixes #105.
## Summary
Read-only list endpoints so the ChicoryTV SPA schedule-editor and channel pickers (#86, #89) can populate their dropdowns:
- `GET /api/filler-presets`
- `GET /api/watermarks`
- `GET /api/graphics-elements`
Each returns a lightweight `(Id, Name)` response model — exactly what the Blazor pickers consume — instead of the full 15+-field ViewModels, keeping the OpenAPI surface clean. Graphics elements reuse `ProjectToViewModel` so API names match the Blazor display names, and reproduce the existing ordering rule (named elements before file-name-only ones).
Built on the salvaged WIP commit: reviewed against conventions, added route `Name=` attributes, handler tests (InMemoryTvContext harness: seeding, DTO projection, empty-DB, graphics ordering), and OpenAPI regen. `TZ=UTC dotnet test ErsatzTV.Tests` → 270 passed.
## Review
Adversarial review of the full diff vs main: no blockers/majors.
- MINOR (parity by design): filler-preset and watermark lists return DB order (no `OrderBy(Name)`), same as the Blazor handlers; SPA should client-sort if it cares.
- The optional languages-list endpoint from the issue is deferred to a follow-up.
- No model/migration changes; migrations job unaffected.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
The WIP GET /api/filler-presets, /api/watermarks, and
/api/graphics-elements endpoints omitted the Name= route attribute
used by the other API GET actions (e.g. FFmpegProfileController). Add
Name = "GetFillerPresets" / "GetWatermarks" / "GetGraphicsElements" for
consistency.
Also add handler tests (FillerPresetHandlerTests, WatermarkHandlerTests,
GraphicsElementHandlerTests) covering the GetAll*ForApi handlers using
the InMemoryTvContext harness: multi-row projection to (Id, Name) DTOs,
the empty-DB case, and the graphics-element ordering rule (named
elements sort before elements whose projected Name equals FileName).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Fixes #105.
Summary
Read-only list endpoints so the ChicoryTV SPA schedule-editor and channel pickers (#86, #89) can populate their dropdowns:
GET /api/filler-presetsGET /api/watermarksGET /api/graphics-elementsEach returns a lightweight
(Id, Name)response model — exactly what the Blazor pickers consume — instead of the full 15+-field ViewModels, keeping the OpenAPI surface clean. Graphics elements reuseProjectToViewModelso API names match the Blazor display names, and reproduce the existing ordering rule (named elements before file-name-only ones).Built on the salvaged WIP commit: reviewed against conventions, added route
Name=attributes, handler tests (InMemoryTvContext harness: seeding, DTO projection, empty-DB, graphics ordering), and OpenAPI regen.TZ=UTC dotnet test ErsatzTV.Tests→ 270 passed.Review
Adversarial review of the full diff vs main: no blockers/majors.
OrderBy(Name)), same as the Blazor handlers; SPA should client-sort if it cares.🤖 Generated with Claude Code