Commit graph

12 commits

Author SHA1 Message Date
Thorsten Bus 0e3c647cfc feat: probundle export with media, image upscaling, upload dimension warnings
- Fix probundle exports missing images (double slides/ prefix in storage path)
- Replace manual ZipArchive with PresentationBundle + ProBundleWriter from parser plugin
- Add per-agenda-item download route and buttons for songs and slide items
- Remove text layer from image-only slides in .pro generation
- Fix image conversion: upscale small images, black bars on 2 sides max (contain)
- Add upload warnings for non-16:9 and sub-1920x1080 images (German, non-blocking)
- Update SlideFactory and all tests to use slides/ prefix in stored_filename
- Add 11 new tests (agenda download, image conversion, upload warnings)
2026-03-30 10:29:37 +02:00
Thorsten Bus 4c119b647d feat: add has_agenda flag to services and guard agenda sync
Events without an agenda in ChurchTools now gracefully set has_agenda=false
instead of throwing errors during sync. The edit/finalize buttons are
disabled in the frontend for services without an agenda.

Also fixes missing cts_song_id column on service_songs table.
2026-03-29 15:22:32 +02:00
Thorsten Bus 31d7634dbf feat(db): add service_agenda_items table + slides FK migration 2026-03-29 11:34:55 +02:00
Thorsten Bus bef910b126 feat(slides): add sort_order column, bulk delete, and reorder endpoints
Add sort_order to slides table with migration and model fillable.
Add destroyBulk() for batch soft-delete by type/service_id and
reorder() for drag-and-drop slide ordering. Auto-assign sort_order
on image and zip uploads.
2026-03-02 23:02:19 +01:00
Thorsten Bus 04d271f96a style: apply Laravel Pint formatting across codebase
Auto-formatted by Laravel Pint (default Laravel preset): string
concatenation spacing, anonymous class brace placement, constructor
body shorthand, import ordering, and assertion indentation.
2026-03-02 23:02:03 +01:00
Thorsten Bus fefa761748 feat(settings): add macro configuration infrastructure
- Migration: settings table with key (unique), value (text), timestamps
- Model: Setting with static get/set helpers using DB upsert
- Controller: SettingsController with index (Inertia) and update (JSON)
- Vue: Settings page with 4 macro fields, auto-save on blur
- Navigation: Einstellungen link in desktop + mobile nav after API-Log
- Shared props: macroSettings added to HandleInertiaRequests
- Integration: ProExportService injects macro into COPYRIGHT group slides
- Gracefully skips macro injection when settings empty/null
2026-03-02 22:00:19 +01:00
Thorsten Bus a36841f920 feat(songs): add CTS song ID matching, info slide date filter, arrangement ordering, translation defaults
- Add cts_song_id column to songs and service_songs for CCLI-free matching fallback
- Filter information slides by uploaded_at <= service date (not shown before upload)
- New arrangements use song's default group ordering instead of cloning
- Auto-set use_translation=true when matched song has translation
- Update syncSongs/syncServiceAgendaSongs to store and use cts_song_id
- Add tests for CTS song ID fallback, upload date filtering, and translation defaults
2026-03-02 14:10:40 +01:00
Thorsten Bus bb25b3b98d feat(logs): store and lazy-load actual API response body in request log
- Add response_body longText column to api_request_logs table
- Store serialized response (max 500KB) in ChurchToolsService::logApiCall
- Add GET /api-logs/{log}/response-body endpoint for lazy loading
- Replace static 'Array mit X Einträgen' with collapsible JSON viewer
- Response body fetched on-demand when user clicks to expand
2026-03-02 13:25:45 +01:00
Thorsten Bus 85111c70e7 feat: add CTS API request logging with searchable frontend UI 2026-03-02 11:01:48 +01:00
Thorsten Bus 3a1ba1fc7d feat(auth): add dummy test login for local dev + update env for Herd
- Update .env.example for Herd (APP_URL, CHURCHTOOLS_REDIRECT_URI)
- Add POST /dev-login route (local/testing only)
- Add "Test-Anmeldung" button to Login.vue
- Update UserFactory with OAuth fields (churchtools_id, avatar, groups, roles)
2026-03-01 22:33:29 +01:00
Thorsten Bus 57d54ec06b feat: Wave 1 Foundation - Database, OAuth, Sync, Files, Layout, Email (T2-T7)
T2: Database Schema + All Migrations
- 10 migrations: users extension, services, songs, song_groups, song_slides,
  song_arrangements, song_arrangement_groups, service_songs, slides, cts_sync_log
- 9 Eloquent models with relationships and casts
- 9 factory classes for testing
- Tests: DatabaseSchemaTest (2 tests, 26 assertions) 

T3: ChurchTools OAuth Provider
- Custom Socialite provider for ChurchTools OAuth2
- AuthController with redirect/callback/logout
- Replaced Breeze login with OAuth-only (German UI)
- Removed all Breeze register/password-reset pages
- Tests: OAuthTest (9 tests, 54 assertions) 

T4: CTS API Service + Sync Command
- ChurchToolsService wrapping 5pm-HDH/churchtools-api
- SyncChurchToolsCommand (php artisan cts:sync)
- SyncController for refresh button
- CCLI-based song matching
- Tests: ChurchToolsSyncTest (2 tests) 

T5: File Conversion Service
- FileConversionService with letterbox/pillarbox to 1920×1080
- ConvertPowerPointJob (queued) with LibreOffice + spatie/pdf-to-image
- ZIP extraction and recursive processing
- Thumbnail generation (320×180)
- Tests: FileConversionTest (2 tests, 21 assertions) 

T6: Shared Vue Components
- AuthenticatedLayout with nav, user info, refresh button
- useAutoSave composable (500ms debounce)
- FlashMessage, ConfirmDialog, LoadingSpinner components
- HandleInertiaRequests middleware with shared props
- Tests: SharedPropsTest (7 tests) 

T7: Email Configuration
- MissingSongRequest mailable (German)
- Email template with song info and service link
- SONG_REQUEST_EMAIL config
- Tests: MissingSongMailTest (2 tests, 10 assertions) 

All tests passing: 30/30 (233 assertions)
All UI text in German with 'Du' form
Wave 1 complete: 7/7 tasks 
2026-03-01 19:39:26 +01:00
Thorsten Bus 1756473701 feat: Laravel 12 scaffolding with Breeze Vue + Docker setup
- Install Laravel 12 with Breeze (Vue stack + Inertia.js)
- Configure Pest testing framework (5 tests passing)
- Add Docker multi-stage build (PHP 8.3 + LibreOffice + ImageMagick)
- Create docker-compose.yml with app + node services
- Configure Vite for Docker hot-reload
- Set app locale to 'de' (German)
- Add Vue packages: @vueuse/core, vue-draggable-plus, vue3-dropzone
- Update .env.example with all project vars
- Relocate spike files: src/Cts/ → app/Cts/ (Laravel autoload)
- Tests: 5 passed (14 assertions)
- Vite build: successful
- Docker: app container running

Task: T1 - Laravel Scaffolding + Breeze Vue + Docker
2026-03-01 19:25:32 +01:00