Commit Graph

123 Commits

Author SHA1 Message Date
SysAdmin Agent
bf47ba11c9 Phase 1: Sidebar-Navigation, Dashboard-Cockpit & HTMX-Integration
- New sidebar layout (6 sections: Dashboard, Personen, Land, Finanzen, Dokumente, System)
- Collapsible sidebar with localStorage persistence
- Top bar with user dropdown and breadcrumbs
- Dashboard cockpit with live KPI cards (Destinataere, Foerderungen, Zahlungen, Laendereien)
- Action items: overdue Nachweise, pending payments, upcoming events, new emails, expiring leases
- Quick actions panel and recent audit log
- HTMX (2.0.4) and Alpine.js (3.14.8) integration via CDN
- django-htmx middleware and CSRF token setup
- Fix IMAP_PORT empty string handling in settings

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-11 10:22:42 +00:00
SysAdmin Agent
3ca2706e5d Phase 0: forms.py, admin.py und views.py in Domain-Packages aufteilen
- forms.py → forms/ Package (8 Domänen: destinataere, land, finanzen,
  foerderung, dokumente, veranstaltung, system, geschichte)
- admin.py → admin/ Package (7 Domänen, alle 22 @admin.register dekoriert)
- views.py (8845 Zeilen) → views/ Package (10 Domänen: dashboard, destinataere,
  land, paechter, finanzen, foerderung, dokumente, unterstuetzungen,
  veranstaltung, geschichte, system)
- __init__.py in jedem Package re-exportiert alle Symbole für Rückwärtskompatibilität
- urls.py bleibt unverändert (funktioniert durch Re-Exports)
- Django system check: 0 Fehler, alle URL-Auflösungen funktionieren

Keine funktionalen Änderungen – reine Strukturverbesserung für Vision 2026.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-11 09:55:15 +00:00
SysAdmin Agent
7e9e4fddf1 Phase 0: Alte models.py entfernt (ersetzt durch models/ Package)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-11 09:04:44 +00:00
SysAdmin Agent
b4bad7bc83 Phase 0: models.py → models/ Package aufgeteilt
models.py (3.496 Zeilen) in 6 Domain-Module aufgeteilt:
- system.py: CSVImport, ApplicationPermission, AuditLog, BackupJob, AppConfiguration, HelpBox
- land.py: Paechter, Land, LandVerpachtung, LandAbrechnung, DokumentLink
- finanzen.py: Rentmeister, StiftungsKonto, BankTransaction, Verwaltungskosten
- destinataere.py: Destinataer, Person, Foerderung, DestinataerUnterstuetzung,
  UnterstuetzungWiederkehrend, DestinataerNotiz, VierteljahresNachweis,
  DestinataerEmailEingang
- veranstaltungen.py: BriefVorlage, Veranstaltung, Veranstaltungsteilnehmer
- geschichte.py: GeschichteSeite, GeschichteBild, StiftungsKalenderEintrag

__init__.py re-exportiert alle Models für volle Rückwärtskompatibilität.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-11 09:02:08 +00:00
SysAdmin Agent
709903e627 Baseline für Vision 2026: Veranstaltungsmodul + ausstehende Änderungen
Alle bestehenden, nicht commiteten Änderungen als Ausgangsbasis für den
vision-2026 Branch übernommen (Veranstaltungsmodul, Serienbrief, etc.).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-11 08:51:48 +00:00
SysAdmin Agent
28621d2774 feat: Veranstaltungsmodul + Serienbrief mit editierbaren Feldern (STI-35, STI-39)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
Implementierung des Veranstaltungsmoduls inkl. Serienbrief-PDF-Generator
mit dynamischen, editierbaren Feldern für Betreff und Unterschriften.

### Veranstaltungsmodul (STI-35)
- Neues Veranstaltungs-Modell: Titel, Datum, Uhrzeit, Ort, Gasthaus-Adresse,
  Briefvorlage, Gästeliste (VerstaltungsGast mit freien/Destinatär-Feldern)
- Views: Veranstaltungsliste, -detail, Serienbrief-PDF-Generator
- Templates: list.html, detail.html, serienbrief_pdf.html (A4, einseitig)
- API: Serializer + Endpunkte für Veranstaltungen
- Admin: Inline-Bearbeitung der Gästeliste
- Migration: 0044_veranstaltungsmodul

### Serienbrief editierbare Felder + PDF-Fix (STI-39)
- Neue Felder an Veranstaltung: betreff, unterschrift_1_name/titel,
  unterschrift_2_name/titel (mit Defaults: Katrin Kleinpaß / Jan Remmer Siebels)
- PDF-CSS: Margins, Font-Sizes und Line-Heights reduziert für einseitigen Druck
- Migration: 0045_add_serienbrief_editable_fields

### Infrastruktur
- scripts/init-paperless-db.sh: Erstellt separate Paperless-DB beim DB-Init
- compose.yml: init-paperless-db.sh eingebunden, PAPERLESS_DBNAME-Fix
- .gitignore: .claude/ ausgeschlossen

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-10 22:36:58 +00:00
SysAdmin Agent
f8f9dc3319 feat: Memory-Konzept für Agents implementieren (STI-21)
- REST API: 9 Read-Only-Endpunkte unter /api/v1/ für alle Kernmodelle
  (Destinatäre, Ländereien, Pächter, Förderungen, Konten,
  Verpachtungen, Verwaltungskosten, Kalender, Transaktionen)
- Token-Authentifizierung via DRF TokenAuthentication
- Management-Command `create_agent_token` für Agent-Tokens
- Wissensbasis: knowledge/ mit Satzung, Richtlinien, Verfahren,
  Kontakte, Historie
- Agent-Instructions: Datenzugriff-Sektion in AGENTS.md dokumentiert

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-09 22:45:11 +00:00
Stiftung CEO Agent
4b21f553c3 feat: Email-Eingangsverarbeitung für Destinatäre implementieren
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
Neues System zur automatischen Verarbeitung eingehender E-Mails von
Destinatären. IMAP-Polling alle 15 Minuten via Celery Beat, automatische
Zuordnung zu Destinatären anhand der E-Mail-Adresse, Upload von Anhängen
zu Paperless-NGX.

Umfasst:
- DestinataerEmailEingang Model mit Status-Tracking
- Celery Task für IMAP-Polling und Paperless-Integration
- Web-UI (Liste + Detail) mit Such- und Filterfunktion
- Admin-Interface mit Bulk-Actions
- Agent-Dokumentation (SysAdmin, RentmeisterAI)
- Dev-Environment Modernisierung (docker compose v2)

Reviewed by: SysAdmin (STI-15), RentmeisterAI (STI-16)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-09 21:11:22 +00:00
6c8ddbb4f0 Getrennte Fristen für Studiennachweis und Zahlung implementieren
Some checks failed
Code Quality / quality (push) Has been cancelled
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
- Neue Felder: studiennachweis_faelligkeitsdatum (semesterbasiert) und zahlung_faelligkeitsdatum (vierteljährlich im Voraus)
- Studiennachweis-Fristen: Q1/Q2 → 15. März, Q3/Q4 → 15. September
- Zahlungsfälligkeiten: Q1 → 15. Dez (Vorjahr), Q2 → 15. Mär, Q3 → 15. Jun, Q4 → 15. Sep
- Auto-Freigabe: Q1 freigeben → Q2 Studiennachweis auto-freigegeben, Q3 → Q4
- Unterstützungserstellung: Verhindert Duplikate durch präzise Suche nach zahlung_faelligkeitsdatum
- Quartalserstellung: Modal-Formular funktioniert korrekt
- UI: Beide Fristen in Tabelle angezeigt, separate Überfälligkeits-Indikatoren
- Migration: Neue Felder hinzugefügt und bestehende Datensätze befüllt
2025-12-30 20:20:33 +01:00
24435660f5 Remove backup media and static directories 2025-12-28 17:28:24 +01:00
Stiftung Development
0493c2c1db fix: Correct Gramps Web environment variable defaults for subpath 2025-10-15 23:02:18 +02:00
Stiftung Development
737a3c5335 fix: Adjust Gramps Web base URL for nginx proxy compatibility 2025-10-15 22:04:07 +02:00
Stiftung Development
a4c773a57d fix: Configure Gramps Web static paths for subpath deployment
- Add GRAMPSWEB_STATIC_PATH and GRAMPSWEB_STATIC_URL environment variables
- Configure proper static file serving for /ahnenforschung subpath
- Fix CSS and JavaScript loading issues in reverse proxy setup
- Ensure Gramps Web initialization page loads correctly
2025-10-15 21:49:21 +02:00
Stiftung Development
c1c6824364 feat: Add Gramps Web genealogy integration
- Add Gramps Web service to both development and production compose files
- Configure Django-Gramps API integration environment variables
- Update production environment template with Gramps configuration
- Enable genealogy features for foundation family tree management
- Gramps Web will be accessible at /ahnenforschung in production
2025-10-15 20:18:20 +02:00
Stiftung Development
b9544048e6 Security: Require authentication for home page view
- Add @login_required decorator to home view function
- Ensures all views now require user authentication
- Prevents unauthorized access to homepage and dashboard
- Part of comprehensive authentication security implementation
2025-10-11 18:11:43 +02:00
f04d93c7f0 feat: Add edit and delete functionality for Verwaltungskosten
- Add verwaltungskosten_delete view with confirmation page
- Add delete URL route and template
- Fix template action buttons to use proper URLs for edit/delete
- Include audit logging for deletions
- Add comprehensive delete confirmation with entry details
- Remove non-functional details button from action group
2025-10-05 23:42:05 +02:00
ca3bf0f296 fix: Use bound fields in rights management system
- Replace raw field objects with bound fields in get_permission_groups()
- Bound fields render properly as HTML checkboxes in templates
- Fixes display of Django field object strings instead of actual form inputs
- Rights management system now shows proper checkboxes with permission names
2025-10-05 23:03:56 +02:00
efd0088124 fix: Improve rights management exception handling
- Add fallback permission object when Permission.DoesNotExist
- Create proper display name from field_name for missing permissions
- Prevents raw Django field objects from being displayed in template
2025-10-05 22:46:44 +02:00
004fcb23ae Enhanced Paperless login redirect fix with monkey patching
- Add monkey patch to Django LoginView.get_success_url() method
- Force redirect to /paperless/ when next parameter is empty or '/'
- Add comprehensive URL configuration for reverse proxy
- Set proper static/media URLs for subpath deployment
- Add USE_X_FORWARDED_HOST and USE_X_FORWARDED_PORT settings

This should definitively fix the redirect issue by intercepting Django's
internal redirect logic and ensuring users stay within Paperless scope.
2025-10-05 21:57:13 +02:00
da66bd356e Fix Paperless login redirect issue
- Configure LOGIN_REDIRECT_URL and LOGOUT_REDIRECT_URL to /paperless/
- Set proper cookie paths for session isolation (/paperless/ instead of /)
- Use environment variables for redirect URLs in paperless_custom_settings.py
- Add PAPERLESS_URL and PAPERLESS_FORCE_SCRIPT_NAME to env template
- Ensure FORCE_SCRIPT_NAME respects environment variable

This fixes the issue where logging into Paperless redirects to the root Django
app instead of staying within the Paperless scope. The docker-compose.yml
already has the correct environment variables set.
2025-10-05 20:57:06 +02:00
544284dd8b Remove obsolete dashboard functionality
- Remove dashboard view from urls.py and views.py
- Delete dashboard.html template
- Remove dashboard navigation link from base.html
- Replace all dashboard redirects with home redirects in views.py
- Update all breadcrumb links from 'Dashboard' to 'Home' in templates
- Update German text from 'Dashboard' to 'Startseite' in auth templates
- Update 'Zurück zum Dashboard' links to 'Zurück zur Startseite'

The dashboard was redundant with the home page functionality.
All navigation now directs users to the main home page instead.
System check passes without issues after removal.
2025-10-05 20:49:48 +02:00
1a40277d66 CRITICAL FIX: Remove duplicate signal handler causing double transactions
- Fixed signals.py which contained two signal handlers creating duplicate transactions
- Removed broken signal handler that created transactions without referenz
- Keep only the proper signal handler with PAY- referenz and duplicate prevention
- This resolves the issue where payments were deducted twice from account balance
- Cleaned up malformed docstring and signal structure in signals.py

The issue was that payments were processed by both:
1. Broken signal handler (empty referenz) - creating first transaction
2. Proper signal handler (PAY- referenz) - creating second transaction

Now only the proper handler runs, preventing double balance deduction.
2025-10-05 00:48:21 +02:00
c289cc3c58 Fix payment system balance integration and add calendar functionality
- Implement automated payment tracking with Django signals
- Fix duplicate transaction creation with unique referenz system
- Add calendar system with CRUD operations and event management
- Reorganize navigation menu (rename sections, move admin functions)
- Replace Geschichte editor with EasyMDE markdown editor
- Add management commands for balance reconciliation
- Create missing transactions for previously paid payments
- Ensure account balances accurately reflect all payment activity

Features added:
- Calendar entries creation and administration via menu
- Payment status tracking with automatic balance updates
- Duplicate prevention for payment transactions
- Markdown editor with live preview for Geschichte pages
- Database reconciliation tools for payment/balance sync

Bug fixes:
- Resolved IntegrityError on payment status changes
- Fixed missing account balance updates for paid payments
- Prevented duplicate balance deductions on re-saves
- Corrected menu structure and admin function placement
2025-10-05 00:38:18 +02:00
2961f376c3 Add Geschichte (History) wiki-style feature with reorganized navigation
🆕 NEW FEATURES:
- Wiki-style Geschichte (History) section with rich text editor
- Image upload support for history pages
- Quill.js rich text editor with formatting options
- Slug-based URLs for SEO-friendly history pages
- Image galleries with descriptions and alt-text support

🔧 MODELS:
- GeschichteSeite: Main history pages with rich content
- GeschichteBild: Image attachments for history pages
- Auto-generated slugs, sorting, publishing controls

📝 TEMPLATES:
- geschichte/liste.html: Card-based overview of all history pages
- geschichte/detail.html: Full page view with image gallery
- geschichte/form.html: Rich text editor for creating/editing pages
- geschichte/bild_form.html: Image upload interface

🎨 UI IMPROVEMENTS:
- Reorganized navigation menu into logical groups:
  * Menschen & Finanzen (People & Finance)
  * Immobilien & Land (Real Estate & Land)
  * Verwaltung (Administration)
  * Geschichte (History)
- More compact menu design saving horizontal space
- Better grouping with dropdown headers

🛠️ TECHNICAL:
- Rich text editor with Quill.js integration
- Image upload with validation and optimization
- Permission-based access controls
- Responsive design for all screen sizes
- Proper breadcrumb navigation
- Auto-slug generation from titles
2025-10-02 21:49:12 +02:00
390bf697ee Fix date field display with readonly TextInput widget
- Changed from disabled DateInput to readonly TextInput for auto-generated payments
- Uses German date format (dd.mm.yyyy) for better user experience
- Added visual styling to indicate readonly state
- Preserves original date value through clean() method
2025-10-02 21:40:01 +02:00
c4308542b9 Fix disabled date field to show current value when editing
- Set initial value for disabled faellig_am field in auto-generated payments
- Explicitly set widget value attribute to display current date
- Ensures the field shows the correct date even when disabled
2025-10-01 14:34:53 +02:00
f01024d981 Fix form validation for disabled due date field
- Changed readonly to disabled for faellig_am field in auto-generated payments
- Added clean method to preserve original due date for auto-generated payments
- This prevents validation errors when editing auto-generated quarterly payments
2025-10-01 14:30:04 +02:00
6b73a0a369 Add transfer data fields to payment form
- Added empfaenger_iban, empfaenger_name, verwendungszweck to DestinataerUnterstuetzungForm
- Made faellig_am read-only for automatically generated quarterly payments
- Added proper placeholders for transfer data fields
- Template already supports these fields in Überweisungsdaten section
2025-10-01 13:47:47 +02:00
c3e0cc0f6a Fix quarterly payment schedule to correct advance payment dates
- Q1: Due December 15 (previous year)
- Q2: Due March 15
- Q3: Due June 15
- Q4: Due September 15

Added new management command fix_quarterly_payment_schedule to update existing payments
2025-10-01 13:12:52 +02:00
6adedc71c5 Fix semester system: 2x yearly docs, 4x yearly payments with Q4 on Sep 15
Document Submission (twice yearly):
- Q1 & Q2 documents: Due March 15 (Spring semester)
- Q3 & Q4 documents: Due September 15 (Fall semester)

Payment Schedule (quarterly):
- Q1 payments: Due March 15
- Q2 payments: Due June 15
- Q3 payments: Due September 15
- Q4 payments: Due September 15 (aligned with Fall semester docs)

This gives the desired Q4 payment due date of 15.09.2025 while maintaining
quarterly payment frequency and semester-based document submissions.
2025-10-01 12:36:47 +02:00
6aa218004c Implement advance payment schedule for quarterly payments
BREAKING CHANGE: Payment due dates now follow advance payment schedule:
- Q1 payments: Due December 15 of previous year
- Q2 payments: Due March 15 of same year
- Q3 payments: Due June 15 of same year
- Q4 payments: Due September 15 of same year

Changes:
- Updated create_quarterly_support_payment() to use advance schedule
- Enhanced diagnostic commands to check advance payment dates
- Added fix_advance_payment_dates command for comprehensive fixes
- Updated fix_q4_payment_dates to correct Q4 from 31.12 to 15.09

This aligns with semester-based document submissions while maintaining
the advance payment system where payments are made before each quarter.
2025-10-01 12:04:34 +02:00
149078aaee Add production diagnostic and fix commands for semester deadlines
- diagnose_deadlines: Check migration status, deadline correctness, and payment patterns
- fix_q4_payment_dates: Fix payments with wrong due dates (31.12 → 15.12)
- includes dry-run modes and detailed reporting
- helps identify why production dates haven't updated

Usage on production:
  python manage.py diagnose_deadlines
  python manage.py fix_q4_payment_dates --dry-run
  python manage.py fix_q4_payment_dates
2025-09-30 22:11:18 +02:00
2bb0bfc432 Add forced migration for semester deadline updates
This migration will automatically run during deployment and update
all existing quarterly confirmation deadlines to the new semester-based system:
- Q1: March 15 (Spring semester primary submission)
- Q2: June 15 (auto-approved when Q1 approved)
- Q3: September 15 (Fall semester primary submission)
- Q4: December 15 (auto-approved when Q3 approved)

No manual intervention required on VPS - GitHub Action will deploy and migrate automatically.
2025-09-30 21:46:09 +02:00
19ea216df6 Add management commands for semester deadline migration
- add update_semester_deadlines: Update quarterly deadlines to semester-based system
- add check_deadlines: Check current deadline status and validation
- includes dry-run mode and year filtering options
- provides clear progress feedback and summaries

Usage on VPS after GitHub Action deployment:
  python manage.py check_deadlines
  python manage.py update_semester_deadlines --dry-run
  python manage.py update_semester_deadlines
2025-09-30 21:39:32 +02:00
656af599bb Implement semester-based quarterly tracking system
- Update quarterly confirmation deadlines to semester-based schedule:
  - Q1: March 15 (covers Spring semester Q1+Q2)
  - Q2: June 15 (auto-approved when Q1 approved)
  - Q3: September 15 (covers Fall semester Q3+Q4)
  - Q4: December 15 (auto-approved when Q3 approved)

- Add auto-approval functionality:
  - Q1 approval automatically approves Q2 with same document status
  - Q3 approval automatically approves Q4 with same document status
  - New 'auto_geprueft' status with distinct badge UI

- Maintain quarterly payment cycle while simplifying document submissions
- Remove modal edit functionality, keep full-screen editor only
- Update copilot instructions documentation

Changes align with academic semester system where students submit
documents twice yearly instead of quarterly.
2025-09-30 21:32:12 +02:00
ed6a02232e feat: Implement TOTP-based Two-Factor Authentication
- Add django-otp and qrcode dependencies
- Create comprehensive 2FA views and templates in German
- Add 2FA setup, verification, and management interfaces
- Implement backup token system with 10 recovery codes
- Add TwoFactorMiddleware for session enforcement
- Integrate 2FA controls into user navigation menu
- Support QR code generation for authenticator apps
- Add forms for secure 2FA operations with validation
- Configure OTP settings and admin site integration

Features:
- Optional 2FA (users can enable/disable)
- TOTP compatible with Google Authenticator, Authy, etc.
- Backup codes for emergency access
- German language interface
- Session-based 2FA enforcement
- Password confirmation for sensitive operations
- Production-ready with HTTPS support
2025-09-30 00:10:02 +02:00
92b689f5e7 Fix User DoesNotExist error in backup_cancel by using created_by_id
🐛 Root Cause Found & Fixed:
- Error occurred when accessing backup_job.created_by where the referenced user was deleted
- Django was trying to fetch a User object that no longer exists
- Changed to use backup_job.created_by_id instead of backup_job.created_by
- This avoids the foreign key lookup that was causing the 'User matching query does not exist' error

 Backup cancellation now works even when:
- Original creator user has been deleted from the database
- Foreign key relationship is broken but ID is still stored

The backup job can now be cancelled without triggering user lookup errors.
2025-09-29 22:14:06 +02:00
c46c3543b1 Add detailed debugging to backup_cancel function
🐛 Debug Enhancement:
- Added extensive print statements to track execution flow
- Identify exact location where 'User matching query does not exist' occurs
- Added traceback logging for better error diagnosis
- Isolated potential problem areas: user access, model saves, audit logging

This will help pinpoint where the user query error happens during backup cancellation.
2025-09-29 20:42:54 +02:00
33888a3b18 Fix backup cancellation user reference issues
🐛 Enhanced Error Handling:
- Fixed 'User matching query does not exist' error in backup_cancel
- Handle case where backup_job.created_by is None (deleted user)
- Added error handling for audit logging to prevent cancellation failure
- Improved permission check to handle null created_by references

 Backup Cancellation Robustness:
- Now works even if the user who created the backup was deleted
- Audit logging failure won't prevent successful cancellation
- Better error isolation and reporting

The error occurred because the system tried to compare a null user reference
or failed during audit logging when user records were inconsistent.
2025-09-29 20:40:51 +02:00
bdcede9a74 Fix BackupJob import error in backup_cancel function
🐛 Error Fixed:
- NameError: name 'BackupJob' is not defined in backup_cancel view
- Added missing 'from stiftung.models import BackupJob' import

 Backup cancellation now works correctly
- Users can cancel long-running backup jobs without errors
- Added local import following the same pattern as other backup functions

The error occurred when trying to cancel a running backup job due to missing model import.
2025-09-29 20:36:52 +02:00
a1ecd31b76 Enhance destinataer list: 50 entries per page + default sort by last name
🎯 Improvements Made:
- Increased pagination from 20 to 50 entries per page
- Added default sorting by last name (nachname) in ascending order
- Added visual sorting indicators with Font Awesome icons (up/down arrows)
- Added results info showing current page range and total count
- Display shows sorting method when active

📊 User Experience:
- List now shows 50 destinataers by default (as requested)
- Always sorted by last name for consistent browsing
- Clear visual feedback for which column is sorted
- Informative pagination showing 'X-Y of Z entries (50 per page)'

 Template & View Changes:
- Modified destinataer_list view in views.py
- Enhanced destinataer_list.html template
- Maintained all existing filtering and search functionality
2025-09-29 20:34:30 +02:00
0d672477af Fix VierteljahresNachweis export error - correct method name
🐛 Error Fixed:
- AttributeError: 'VierteljahresNachweis' object has no attribute 'completion_percentage'
- Line 5347 in destinataer_export view was calling completion_percentage()
- Corrected to call get_completion_percentage() which is the actual method name

 Export functionality now works correctly for destinataers with quarterly confirmations

The error occurred when exporting a destinataer that had quarterly tracking data.
All quarterly confirmation completion percentages are now properly exported.
2025-09-28 21:25:15 +02:00
994eb789b7 Fix quarterly tracking visibility and prevent duplicate support payments
🎯 Key Changes:
- Quarterly tracking now always visible (removed studiennachweis_erforderlich condition)
- Removed automatic support payment creation when 'Unterstützung bestätigt' checkbox is checked
- Support payments now ONLY created through quarterly confirmation approval workflow
- Updated auto-creation logic to create quarterly confirmations for ALL destinataers
- Updated 'no quarterly confirmations' message to be more user-friendly

🚫 Duplicate Prevention:
- No more duplicate destinataer entries in Unterstützungen list
- Single source of truth: quarterly confirmation system controls support payment creation

📋 Template Analysis:
- Reviewed all if/else statements in quarterly tracking section
- Kept all functional logic (status checks, file existence, permissions)
- Removed only the visibility-controlling conditions

 Result:
- Quarterly tracking always visible regardless of study proof requirements
- Clean separation between 'Unterstützung bestätigt' checkbox and support payment creation
- Eliminates the duplicate destinataer issue reported by user
2025-09-28 19:52:03 +02:00
remmerinio
4752735357 Delete app/media.backup.20250924_232119 directory 2025-09-28 19:12:20 +02:00
acac8695fd Enhanced quarterly confirmation system with approval workflow and export improvements
Features added:
-  Fixed quarterly confirmation approval system with URL pattern
-  Added re-approval and status reset functionality for quarterly confirmations
-  Synchronized quarterly approval status with support payment system
-  Enhanced Destinataer export with missing fields (anrede, titel, mobil)
-  Added quarterly confirmation data and documents to export system
-  Fixed address field display issues in destinataer template
-  Added quarterly statistics dashboard to support payment lists
-  Implemented duplicate support payment prevention and cleanup
-  Added visual indicators for quarterly-linked support payments

Technical improvements:
- Enhanced create_quarterly_support_payment() with duplicate detection
- Added get_related_support_payment() method to VierteljahresNachweis model
- Improved quarterly confirmation workflow with proper status transitions
- Added computed address property to Destinataer model
- Fixed template field mismatches (anrede, titel, mobil vs strasse, plz, ort)
- Enhanced backup system with operation tracking and cancellation

Workflow enhancements:
- Quarterly confirmations now properly sync with support payments
- Single support payment per destinataer per quarter (no duplicates)
- Approval button works for both eingereicht and geprueft status
- Reset functionality allows workflow restart
- Export includes complete quarterly data with uploaded documents
2025-09-28 19:09:08 +02:00
b00cf62d87 Add IBAN and Verwendungszweck columns to support list and fix chart growing bug
- Enhanced 'Alle Unterstützungen' view with IBAN and Verwendungszweck columns for better payment tracking
- Updated export functions to handle both legacy 'selected_fields' and new 'fields' parameters
- Added IBAN and Verwendungszweck to default export field selections
- Improved destinataer list UI by adding Status column and removing obsolete study proof field
- Fixed infinite growing animation bug in 'Größen der Grundstücke (Top 30)' chart by replacing Chart.js with CSS-based implementation
- Removed Bootstrap h-100 class conflicts that caused chart resize loops
2025-09-24 22:13:27 +02:00
d3ed13dda0 fix: Simplify deployment to build from source instead of using pre-built images
- Remove complex GHCR image pulling logic that was causing deployment failures
- Always build containers from source code on production server
- Remove unused build job that pushes to container registry
- Use docker-compose up -d --build to ensure latest code is built and deployed
- This ensures all new features like quarterly confirmations are available in production
2025-09-24 00:13:54 +02:00
126f68ec68 feat: Implement quarterly confirmation system with automatic support payments
- Add VierteljahresNachweis model for quarterly document tracking
- Remove studiennachweis_erforderlich field (now always required)
- Fix modal edit view to include studiennachweis section
- Implement automatic DestinataerUnterstuetzung creation when requirements met
- Set payment due dates to exact quarter end dates (Mar 31, Jun 30, Sep 30, Dec 31)
- Add quarterly confirmation CRUD views with modal and full-screen editing
- Update templates with comprehensive quarterly management interface
- Include proper validation, status tracking, and progress indicators
2025-09-23 23:52:44 +02:00
Stiftung Development
0184982f8c Add production environment update instructions
- Created PRODUCTION_ENV_UPDATE.md with step-by-step fix for CookieError
- Provides SSH commands to add missing SESSION_COOKIE_NAME and CSRF_COOKIE_NAME
- Includes verification steps to confirm fix works
2025-09-21 22:55:37 +02:00
Stiftung Development
36c66a803c Fix cookie configuration and update destinataer workflow
- Fixed empty cookie name issue in production by improving fallback logic
- Changed 'Neue Förderung' to 'Neue Unterstützung' in destinataer detail page
- Updated icon from fa-gift to fa-heart for better UX
- Workflow now correctly uses unterstuetzung_create with destinataer pre-population

Resolves CookieError: Illegal key '' in production environment
2025-09-21 22:52:55 +02:00