Files
jachty.pkmp.com.pl/.paul/changelog/2026-05-07.md
2026-05-08 00:12:37 +02:00

39 lines
3.1 KiB
Markdown

# 2026-05-07
## Co zrobiono
- [Faza 9, Plan 04] Globalna sync iCal (tryb wspólny kalendarz) + nowy widget "wszystkie jachty"
- Settings: nowe pole "Tryb synchronizacji iCal" (per_yacht / global) z whitelistą i bezpiecznym defaultem
- ICal_Import: rozgałęzienie `run_per_yacht_mode()` / `run_global_calendar_mode()`, nowa stała `GLOBAL_CALENDAR_SOURCE`, niezależny cleanup obu trybów
- REST: nowy endpoint `GET /availability/all` (timed 12:00→12:00, kolory z palety per-jacht, privacy w title)
- Frontend: widget Elementor `Calendar_Widget_All` + shortcode `[yacht_calendar_all]` z layoutem 2-kolumnowym (kalendarz + formularz inquiry z wyborem jachtu)
- Privacy hardening: REST nie wystawia `customer_name` w title eventów (defense-in-depth: JS `eventContent` zwraca pusty html)
- UX iteracje po checkpoincie: ciemny styl kalendarza (emulacja `/rezerwacja-maja/`), select w spójnym stylu z innymi inputami, instrukcja, server-side legenda, kolor wspólnych eventów `#7fb3d5` (jasnoniebieski)
- Bump wersji pluginu 1.0.0 → 1.1.0
- [Faza 9, Plan 05] UX rezerwacja — tytuły rezerwacji z GCal w paskach kalendarza zbiorczego + per-day allDay events
- REST `/availability/all`: title z `_booking_notes` (raw iCal SUMMARY bez prefiksu "GCal:") lub `customer_name` (frontend), split per-day allDay events (start INCLUSIVE → end INCLUSIVE) z extendedProps.is_first / is_last_night
- Frontend JS: `eventContent` renderuje `.yc-event-title` (XSS-safe przez `.text()`), half-day gradient na flagach extendedProps, native `title` tooltip na hover
- CSS: usunięte `display:none` z tytułu, nowy `.yc-event-title` (ellipsis), `margin: 1px 2px` na evencie (gap między dziennymi paskami)
- Auto-fix po checkpoincie: zmiana z timed 12:00→12:00 events na allDay (timed crossowały północ → schodki w grid)
- Świadome cofnięcie privacy z 09-04 — tytuły rezerwacji widoczne publicznie per żądanie klienta (security audit 09-06 ma to przeanalizować)
- Bump wersji pluginu 1.1.0 → 1.2.0
## Zmienione pliki
- `wp-content/plugins/yacht-booking-system/yacht-booking-system.php`
- `wp-content/plugins/yacht-booking-system/includes/class-settings.php`
- `wp-content/plugins/yacht-booking-system/includes/class-installer.php`
- `wp-content/plugins/yacht-booking-system/includes/class-yacht-booking.php`
- `wp-content/plugins/yacht-booking-system/admin/class-admin.php`
- `wp-content/plugins/yacht-booking-system/integrations/ical/class-ical-import.php`
- `wp-content/plugins/yacht-booking-system/api/class-rest-controller.php`
- `wp-content/plugins/yacht-booking-system/frontend/class-shortcode.php`
- `wp-content/plugins/yacht-booking-system/frontend/class-calendar-widget-all.php` (nowy)
- `wp-content/plugins/yacht-booking-system/frontend/assets/css/calendar-all.css` (nowy)
- `wp-content/plugins/yacht-booking-system/frontend/assets/js/calendar-all.js` (nowy)
- `test-overlap-bookings.php` (test helper, do skasowania z FTP po teście)
- `.paul/phases/09-finalizacja/09-04-PLAN.md`
- `.paul/phases/09-finalizacja/09-04-SUMMARY.md`
- `.paul/phases/09-finalizacja/09-05-PLAN.md`
- `.paul/phases/09-finalizacja/09-05-SUMMARY.md`