Commit Graph

22 Commits

Author SHA1 Message Date
Claude Agent
0b497157ad feat: landing refăcut + înveliș public unificat pentru login/register/book
Landing:
- hero cu un singur CTA (scoase „Vezi cum arată", „Rezervă fără cont" și nota)
- „Spații deschise rezervării acum" pe poziția 2, în bandă evidențiată cu accent;
  listează toate proprietățile publice active (fără filtrul list_on_landing)
- showcase-ul mutat în bandă neutră etichetată „Demonstrație" ca să nu se
  confunde cu controale reale

Pagini publice:
- PublicNav.vue + PublicFooter.vue extrase și refolosite de Landing, LegalPage
  și noul PublicShell.vue (login/register/book primesc header/footer de landing,
  cu cele 8 teme; tokenii --color-* remapați la paleta landing în scope-ul shell)
- pe mobil: nav compact cu meniu hamburger (drawer ancorat dreapta, iconițe
  lucide, închidere la tap în afară/Escape); logo-ul Romfast rămâne în footer

Fix-uri:
- QR-ul proprietății encodează URL-ul cu slug (fallback pe id)
- deep-link-urile către rutele manager/admin nu mai sar la /dashboard:
  guard-ul așteaptă authStore.ready înainte de verificarea rolurilor
- drawer-ul nu se mai închidea singur la tap pe iconiță (listener pe pointerdown
  + gardă pentru target detașat după re-render)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-13 08:56:23 +00:00
Claude Agent
212b66c758 fix(qa): randează codul QR în cardul de link public
Două probleme, ambele găsite la QA în browser:
- `qrcode` e CommonJS; sub Vite metodele stau pe `.default`, deci
  `QRCode.toCanvas` era undefined → throw prins de un catch gol (blank canvas).
- `renderQr()` era apelat în load() înainte ca ref-ul canvas să fie montat,
  și nu se relua. Adăugat un watch care randează când canvas + is_public sunt gata.

Verificat live: canvas 512x512, QR desenat, buton „Descarcă QR" activ.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-11 19:15:31 +00:00
Claude Agent
a15951c645 feat: sistem de linkuri publice pentru proprietăți
Expune fluxul de rezervare anonimă printr-un link public partajabil
(/book/<slug>), cu calendar public, cod QR și proprietate demo publică.

Backend:
- slug + list_on_landing pe Property; utilitar slugify (diacritice RO,
  cuvinte rezervate, ban all-digit) + migrare idempotentă raw-DDL rulată
  din entrypoint; SQLite WAL + busy_timeout
- GET /public/properties/{slug_or_id}(+/spaces): rezolvare slug/ID, 404 uniform
- GET /public/spaces/{id}/busy: doar {start_time,end_time} (fără PII),
  pending+approved, tz-aware/interval>60z → 422, orfan/privat → 404
- availability: scrub user_name/title (fix scurgere PII)
- POST /public/bookings: overlap pending+approved, cap 5/email/spațiu/zi,
  rate-limit per-IP, suprimare notificări+email pe demo, email confirmare guest
- PATCH slug (409 duplicat / 422 format / 403 non-manager); guest_email EmailStr
- email guest la aprobare/respingere cu cod #RB-<id>
- teste noi: test_public.py + test_migrate_slug.py (33 teste)

Frontend:
- rută /book/:slug; PublicBooking rescris cu calendar grid manual
  (PublicCalendar + GuestBookingForm), 30min, 08-20, mobil day-view, RO
- card „Link public" în PropertyDetail: copy, edit slug, QR pe URL-ul cu ID
- secțiune proprietăți publice + CTA pe Landing; buton copy în Properties

Gate aprobat (U1-U3, G1 grid manual, G2 list_on_landing); G3-G5 în TODOS.md.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-11 19:04:58 +00:00
Claude Agent
98059a8a70 feat: cont demo public cu resetare automată a datelor la 3 ore
- Cont demo (demo@example.com/demo1234) activ implicit, identificat prin
  settings.demo_email — fără configurare în env; DEMO_EMAIL="" îl dezactivează
- Contul demo nu poate fi modificat prin API (email/parolă/status blocate 403)
- reset_demo.py: șterge idempotent toate datele demo și recrează proprietatea
  demo cu 3 spații și 5 rezervări exemplu cu date relative la ziua curentă
- entrypoint.sh: reset la boot + buclă la 3h (DEMO_RESET_INTERVAL)
- start.sh (dev): reset la fiecare pornire
- Login.vue: hint cu credențialele demo (click = precompletare) și mesajul
  de resetare la 3 ore

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-10 20:07:16 +00:00
Claude Agent
c5a882ba6f feat(frontend): mockup-uri realiste ale aplicației în landing
- logo Romfast mărit; iconița aplicației (indigo) lângă „ROA Space"
- „ROA Space" în culoarea reală a aplicației (#6366f1)
- înlocuit secțiunile benefit cu screenshot-uri fidele: Dashboard, Spaces, calendar
- cardul din hero adus la același stil de screenshot al aplicației
- spațiere mai strânsă și curățat CSS-ul nefolosit

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 19:32:56 +00:00
Claude Agent
9bf407b841 style(frontend): „ROA Space" colorat cu accentul temei în antetul landing
Titlul din antetul landing-ului și al paginilor legale folosește acum
culoarea de brand (accentul temei active), lângă siglă, în loc de text
închis.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 18:40:50 +00:00
Claude Agent
38902413f7 fix(frontend): URL corect Contact (romfast.ro/menu/contact.html)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 18:23:13 +00:00
Claude Agent
d54a1987e3 fix(frontend): Contact spre romfast.ro/contact; logo unic link spre home
- Linkurile Contact (footer landing + pagini legale, referința din
  Termeni) duc acum la https://romfast.ro/contact; pagina internă
  /contact și ruta ei au fost eliminate
- Pe paginile legale doar sigla e link către homepage; titlul
  „ROA Space" nu mai e link

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 18:21:31 +00:00
Claude Agent
b2080e79b2 feat(frontend): pagini Termeni, Confidențialitate/GDPR și Contact
Activează linkurile din footer-ul landing-ului către pagini reale,
în stilul paginilor statice din autopass.

- Componentă comună LegalPage.vue: același antet (brand + selector
  de temă), footer și paletă (8 teme) ca landing-ul, cu slot "prose"
- Logica temei extrasă în composable useLandingTheme (partajat de
  landing și paginile legale, persistat în localStorage)
- Rute publice /termeni, /confidentialitate, /contact (fullBleed)
- Footer-ul (landing + pagini) trimite acum la aceste rute

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 18:10:17 +00:00
Claude Agent
fd36483cf2 feat(frontend): landing page ROA Space cu selector de temă
Pagină de prezentare la ruta `/` (redirect la dashboard pentru
utilizatorii autentificați), în stilul design system-ului Romfast,
importată din Claude Design (ROA Space Landing).

- Hero cu card de rezervare interactiv, secțiuni de beneficii,
  bandă CTA discretă și footer pe un singur rând (stil autopass)
- Selector de temă în header cu aceleași 8 teme ca aplicația/autopass
  (light, dark, petrol, grafit, cobalt, cupru, hârtie, auto),
  persistat în localStorage; toată paleta e condusă de tema activă
- Conținut încadrat la 1280px, centrat, cu margini în culoarea temei;
  mod `fullBleed` în App.vue pentru pagini edge-to-edge
- Fonturi Plus Jakarta Sans / Manrope / Space Grotesk în index.html

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 18:02:53 +00:00
Claude Agent
7ce430cc1d feat(security): harden for production deployment
- auth: first registered user becomes superadmin (active immediately)
- entrypoint: no longer seeds demo data in prod (opt-in via RUN_SEED=1)
- config: refuse to boot in prod with weak/placeholder SECRET_KEY (<32 chars)
- main: restrict CORS to FRONTEND_URL only in prod (localhost dev-only)
- seed_db: block prod seeding, read passwords from env, stop printing them
- login: remove demo account credentials from UI

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-25 19:44:20 +00:00
Claude Agent
e21cf03a16 feat: add multi-tenant system with properties, organizations, and public booking
Implement complete multi-property architecture:
- Properties (groups of spaces) with public/private visibility
- Property managers (many-to-many) with role-based permissions
- Organizations with member management
- Anonymous/guest booking support via public API (/api/public/*)
- Property-scoped spaces, bookings, and settings
- Frontend: property selector, organization management, public booking views
- Migration script and updated seed data

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 00:17:21 +00:00
Claude Agent
d637513d92 fix: allow admin to edit any booking via admin endpoint 2026-02-12 15:37:17 +00:00
Claude Agent
d245c72757 feat: complete UI/UX overhaul - dashboard unification, calendar UX, mobile optimization
- Dashboard redesign as command center with filters, quick actions, inline approve/reject
- Reusable components: BookingRow, BookingFilters, ActionMenu, BookingPreviewModal, BookingEditModal
- Calendar: drag & drop reschedule, eventClick preview modal, grid/list toggle
- Mobile: segmented control bookings/calendar toggle, compact pills, responsive layout
- Collapsible filters with active count badge
- Smart menu positioning with Teleport
- Calendar/list bidirectional data sync
- Navigation: unified History page, removed AdminPending
- Google Calendar OAuth integration
- Dark mode contrast improvements, breadcrumb navigation
- useLocalStorage composable for state persistence

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 15:34:47 +00:00
Claude Agent
a4d3f862d2 fix(dashboard): sidebar theming, calendar reactivity, and booking filters
Fix multiple dashboard and UI issues:

Frontend fixes:
- Fix sidebar remaining dark on light theme (add proper light/dark CSS variables)
- Fix DashboardCalendar blank/not showing events (use watch + calendar API instead of computed options)
- Fix upcoming bookings to include active and recent past (last 7 days) bookings
- Improve sidebar collapsed state UX (stack footer buttons vertically, full width)

Details:
- theme.css: Add light sidebar colors (white bg) for :root, keep dark colors for [data-theme="dark"]
- DashboardCalendar: Add watch on events, use calendarRef to update events via removeAllEvents/addEventSource
- Dashboard: Change upcoming filter from "startDate >= now" to "endDate >= 7 days ago"
- AppSidebar: Stack footer-actions vertically when collapsed for better visibility

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-12 10:30:43 +00:00
Claude Agent
28685d8254 feat(dashboard): redesign with active bookings, calendar, and compact stats
Major Dashboard improvements focusing on active reservations and calendar view:

Frontend changes:
- Add ActiveBookings component showing in-progress bookings with progress bars
- Add DashboardCalendar component with read-only calendar view of all user bookings
- Refactor Dashboard layout: active bookings → stats grid → calendar → activity
- Remove redundant Quick Actions and Available Spaces sections
- Make Quick Stats compact (36px icons, 20px font) and clickable (router-link)
- Add datetime utility functions (isBookingActive, getBookingProgress, formatRemainingTime)
- Fix MyBookings to read status query parameter from URL
- Auto-refresh active bookings every 60s with proper cleanup

Backend changes:
- Add GET /api/bookings/my/calendar endpoint with date range filtering
- Fix Google Calendar sync in reschedule_booking and admin_update_booking
- Add Google OAuth environment variables to .env.example

Design:
- Dark mode compatible with CSS variables throughout
- Mobile responsive (768px breakpoint, 2-column stats grid)
- CollapsibleSection pattern for all dashboard sections
- Progress bars with accent colors for active bookings

Performance:
- Optimized API calls (calendar uses date range filtering)
- Remove duplicate calendar data loading on mount
- Computed property caching for stats and filtered bookings
- Memory leak prevention (setInterval cleanup on unmount)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-12 10:21:32 +00:00
Claude Agent
72f46b1062 fix: improve UI responsiveness and formatting across multiple views
- SpaceDetail: Add responsive CSS for FullCalendar mobile layout
  - Stack toolbar elements vertically on mobile (≤768px)
  - Reduce font sizes and padding for compact display
  - Fix overlapping navigation controls and day headers

- Spaces: Add labeled location field with icon
  - Display "Location:" label with MapPin icon
  - Ensure consistent formatting across all space cards

- Dashboard (Admin): Format activity event names
  - Convert snake_case to Title Case (booking_approved → Booking Approved)
  - Improve readability of activity log

- VerifyEmail: Improve mobile button positioning
  - Stack email input and resend button vertically on mobile
  - Add proper padding to prevent edge-touching
  - Make button full-width for better tap targets

These changes improve UI consistency, mobile responsiveness, and user experience
across the application. Coverage improvement: 32% → 93% in Playwright tests.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-12 09:51:51 +00:00
Claude Agent
0bf3e6a7e2 feat: complete UI redesign with dark mode, sidebar navigation, and modern design system
Implemented comprehensive UI overhaul with three-layer architecture:

Layer 1 - Theme System:
- CSS variables for light/dark themes (theme.css)
- Theme composable with light/dark/auto mode (useTheme.ts)
- Sidebar state management composable (useSidebar.ts)
- Refactored main.css to use CSS variables throughout

Layer 2 - Core Components:
- AppSidebar with collapsible navigation (desktop) and overlay (mobile)
- CollapsibleSection reusable component for expandable cards
- Restructured App.vue with new sidebar layout
- Integrated Lucide icons library (lucide-vue-next)

Layer 3 - Views & Components:
- Updated all 14 views with CSS variables and responsive design
- Replaced inline SVG with Lucide icon components
- Added collapsible sections to Dashboard, Admin pages, UserProfile
- Updated 3 shared components (BookingForm, SpaceCalendar, AttachmentsList)

Features:
- Dark/light/auto theme with persistent preference
- Collapsible sidebar (icons-only on desktop, overlay on mobile)
- Consistent color palette using CSS variables
- Full responsive design across all pages
- Modern minimalist aesthetic with Indigo accent color

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 21:27:05 +00:00
Claude Agent
9c2846cf00 feat: add per-space timezone settings and improve booking management
- Add timezone configuration per space with fallback to system default
- Implement timezone-aware datetime display and editing across frontend
- Add migration for per_space_settings table
- Update booking service to handle timezone conversions properly
- Improve .gitignore to exclude build artifacts
- Add comprehensive testing documentation

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 15:54:51 +00:00
Claude Agent
6edf87c899 refactor(frontend): simplify booking forms and convert to modals
- Simplify BookingForm: remove recurring bookings, templates, and attachments
- Replace datetime-local with separate date/time inputs for better UX
- Convert inline forms to modals (Admin spaces, Users, SpaceDetail)
- Unify Create and Edit booking forms with identical styling and structure
- Add Space field to Edit modal (read-only)
- Fix calendar initial load and set week start to Monday
- Translate all form labels and messages to Romanian

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 15:36:22 +00:00
Claude Agent
b93b8d2e71 fix: implement timezone-aware datetime display and editing
All datetime values are stored in UTC but were displaying raw UTC times
to users, causing confusion (e.g., 10:00 Bucharest showing as 08:00).
This implements proper timezone conversion throughout the app using each
user's profile timezone setting.

Changes:
- Frontend: Replace local formatters with timezone-aware utilities
- Backend: Add timezone conversion to PUT /bookings endpoint
- FullCalendar: Configure to display events in user timezone
- Fix edit modal to preserve times when editing bookings

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 13:43:31 +00:00
Claude Agent
df4031d99c feat: Space Booking System - MVP complet
Sistem web pentru rezervarea de birouri și săli de ședință
cu flux de aprobare administrativă.

Stack: FastAPI + Vue.js 3 + SQLite + TypeScript

Features implementate:
- Autentificare JWT + Self-registration cu email verification
- CRUD Spații, Utilizatori, Settings (Admin)
- Calendar interactiv (FullCalendar) cu drag-and-drop
- Creare rezervări cu validare (durată, program, overlap, max/zi)
- Rezervări recurente (săptămânal)
- Admin: aprobare/respingere/anulare cereri
- Admin: creare directă rezervări (bypass approval)
- Admin: editare orice rezervare
- User: editare/anulare rezervări proprii
- Notificări in-app (bell icon + dropdown)
- Notificări email (async SMTP cu BackgroundTasks)
- Jurnal acțiuni administrative (audit log)
- Rapoarte avansate (utilizare, top users, approval rate)
- Șabloane rezervări (booking templates)
- Atașamente fișiere (upload/download)
- Conflict warnings (verificare disponibilitate real-time)
- Integrare Google Calendar (OAuth2)
- Suport timezone (UTC storage + user preference)
- 225+ teste backend

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 17:51:29 +00:00