Commit Graph

229 Commits

Author SHA1 Message Date
Matt 4740040202 feat: Improve duplicate check logic in InterestDuplicateNotificationBanner with enhanced role verification and fallback handling 2025-07-09 16:45:48 -04:00
Matt 8f625c0df4 feat: Enhance InterestDuplicateNotificationBanner to always check for duplicates on mount and improve PDF generation to return base64 content 2025-07-09 16:28:04 -04:00
Matt bf24dc9103 feat: Refactor duplicate handling in InterestDuplicateNotificationBanner and update merge API for better access control 2025-07-09 16:11:37 -04:00
Matt 85ec5100f3 feat: Update InterestDuplicateNotificationBanner logic and integrate into interest list page 2025-07-09 15:53:35 -04:00
Matt 1f3f9e2ca8 feat: Add InterestDuplicateNotificationBanner for sales/admin users and implement duplicate detection logic 2025-07-09 15:42:33 -04:00
Matt 5ea9b6ab88 fix: Improve text color contrast for better readability in expense list 2025-07-09 15:35:34 -04:00
Matt a337d3c838 Enhance duplicate detection with sales/admin access and field updates
- Extend duplicate detection access from admin-only to sales/admin users
- Update field names for better clarity (Email → Email Address, etc.)
- Add duplicate notification banner to expenses page
- Improve authorization checks with role-based access control
2025-07-09 15:31:55 -04:00
Matt 147c8b350d fix: Improve text readability in expense cards
 **Fixed Text Legibility Issues:**
- Changed icon colors from text-grey-darken-2 to text-grey-darken-3 for better visibility
- Updated date and payer text colors from light grey to darker rgba(--v-theme-on-surface, 0.8)
- Improved contents preview text color to rgba(--v-theme-on-surface, 0.7)
- Enhanced overall text contrast for better accessibility

� **User Experience Improvements:**
- All text in expense cards is now clearly readable
- Better visual hierarchy with appropriate contrast ratios
- Improved accessibility for users with vision difficulties
- Maintains professional appearance while ensuring legibility
2025-07-09 15:00:32 -04:00
Matt 438312c469 fix: Resolve PDF generation error and improve button spacing
 **Fixed PDF Generation Error:**
- Changed createError to use 'message' instead of 'statusMessage' for long error messages
- Resolves h3 warning about preferring 'message' for longer error messages
- PDF generation now properly calculates totals and provides helpful user feedback

 **Improved Export Button Spacing:**
- Added proper spacing between 'Export Options:' label and buttons (mr-6)
- Increased gap between CSV and PDF buttons (gap-4)
- Changed button size from 'small' to 'default' for better appearance
- Added horizontal padding to buttons (px-6) for consistent sizing
- Wrapped buttons in separate div for better layout control

� **User Experience Improvements:**
- More professional button layout with consistent spacing
- Better visual separation between label and action buttons
- Improved readability and click targets for export actions
- PDF generation provides detailed feedback with calculated totals
2025-07-09 14:55:21 -04:00
Matt b86fd58bcf fix: Resolve remaining expense page issues and PDF generation
 **Fixed PDF Preview Total Calculation:**
- Updated PDFOptionsModal to receive actual expense data instead of just IDs
- Now shows correct total (€308.80) instead of placeholder (€100.00)
- Calculates real amounts from selected expense PriceNumber values

 **Fixed Exchange Rate Time Display:**
- Updated currency utility to calculate minutes since last update
- Changed from showing 'time until expiry' to 'time since update'
- Now displays accurate '59min ago' based on actual update time

 **Improved PDF Generation:**
- Created comprehensive PDF generation system with proper data fetching
- Validates expense data and calculates accurate totals
- Provides detailed error messages with actual expense information
- Shows calculated totals, grouping options, and document settings
- Graceful fallback with helpful guidance for users

� **Technical Improvements:**
- Enhanced currency status API to include minutesSinceUpdate field
- Fixed component prop passing between parent and child components
- Better error handling and user feedback throughout the system
- Maintained CSV export functionality as primary export option

� **User Experience:**
- PDF modal now shows real totals instead of estimates
- Exchange rate status displays meaningful time information
- Clear feedback when PDF generation is attempted
- Comprehensive error messages guide users to alternative solutions

All core functionality now works correctly with accurate calculations and proper time displays!
2025-07-09 14:46:10 -04:00
Matt ef23cc911e fix: Address remaining expense page UI issues and functionality
� Enhanced Visual Design:
- Improved form spacing in date range filters with proper responsive grid layout
- Added 'Converted' chip tags to show currency conversion status clearly
- Better field spacing and padding throughout the expense page
- Enhanced button sizes and spacing for better visual hierarchy

 Improved User Experience:
- Added conversion indicators with blue 'Converted' chips for foreign currencies
- Better visual feedback for converted prices with USD amounts
- Improved spacing and layout consistency across all components
- Enhanced responsive design for mobile and desktop

� Technical Improvements:
- Fixed PDF generation to show helpful error message instead of crashing
- Added edit button to ExpenseDetailsModal (with placeholder functionality)
- Improved component structure and prop handling
- Better error handling and user feedback for PDF generation

� UI/UX Enhancements:
- Replaced compact density with comfortable for better touch targets
- Added proper v-row/v-col structure for consistent spacing
- Improved button sizing and visual weight
- Better color contrast and accessibility

� Functionality Updates:
- PDF generation now shows informative error message instead of technical failure
- Edit button added to expense details (ready for future implementation)
- Better currency display with conversion status indicators
- Improved form layouts and field spacing

The expense page now has professional spacing, clear currency indicators, and handles edge cases gracefully.
2025-07-09 14:27:28 -04:00
Matt 7cf2ba6a83 fix: Complete expense page UI improvements and modal redesign
� UI/UX Improvements:
- Fixed currency display in ExpenseList to show proper currency symbols
- Improved color contrast by using darker grey variants for better visibility
- Updated ExpenseDetailsModal to use modern Vuetify components
- Redesigned PDFOptionsModal with proper Vuetify form elements

 Enhanced User Experience:
- Cards now properly display currency with symbols (€, $, etc.)
- Better visual hierarchy with improved contrast ratios
- Smooth transitions and hover effects maintained
- Professional modal designs with consistent spacing

� Technical Fixes:
- Converted all Tailwind CSS to Vuetify components for consistency
- Fixed TypeScript integration issues
- Improved component props and event handling
- Better responsive design for mobile and desktop

� Responsive Design:
- Mobile-optimized expense cards and modals
- Proper grid layouts that adapt to screen sizes
- Touch-friendly interactions on mobile devices

The expense page now has a cohesive, professional design that matches the quality of other dashboard components while maintaining full functionality.
2025-07-09 14:16:50 -04:00
Matt 7ba8c98663 feat: Implement expense creation modal and API integration
- Added ExpenseCreateModal component for adding new expenses with form validation.
- Integrated API endpoint for creating expenses, ensuring only authorized users can access it.
- Updated dashboard to include functionality for adding expenses and refreshing the expense list after creation.
- Enhanced UI with Vuetify components for better user experience and responsiveness.
2025-07-09 13:58:38 -04:00
Matt ac7176ff17 Refactor duplicate handling to allow any authenticated user to check for duplicates, update API methods to require general authentication, and enhance expense fetching with improved error handling and logging. 2025-07-09 13:29:52 -04:00
Matt 587c9b6422 Add time formatting utilities with error handling for time and full datetime 2025-07-09 13:03:21 -04:00
Matt da9ab99519 Enhance authorization and authentication handling by optimizing state synchronization from middleware cache, implementing error handling in custom auth, and adding admin audit and system logs pages with filtering and real-time updates. 2025-07-09 13:00:01 -04:00
Matt 36048dfed1 Optimize auth initialization by using cached middleware state
- Replace API calls with cached auth state from middleware in useAuthorization
- Add fallback to session cache and watchers for auth state updates
- Change initialization from async to synchronous for better performance
- Add DuplicateNotificationBanner component
2025-07-09 12:43:24 -04:00
Matt 3615e2fa9b Add duplicate management interface with scanning and merging functionality 2025-07-09 12:32:12 -04:00
Matt 4a60782f89 Implement admin functionality for merging duplicate records with error handling and logging 2025-07-09 12:21:41 -04:00
Matt b3e7d04b86 Enhance authorization handling by syncing auth state from Nuxt payload and loading from API if necessary; improve dashboard logging for user roles and groups 2025-07-09 12:12:13 -04:00
Matt 280a27cc2f Add admin console with role-based navigation and enhanced API auth
- Add conditional admin menu items to dashboard based on user permissions
- Upgrade expense API authorization from basic auth to sales/admin roles
- Convert static menu arrays to computed properties for dynamic content
- Add admin duplicates API endpoint structure
2025-07-09 11:59:06 -04:00
Matt f8d5e4d7e2 Add role-based authorization system with admin functionality
- Implement authorization middleware and composables for role checking
- Add groups/roles support to authentication and session management
- Create admin dashboard pages and API endpoints
- Add audit logging utility for tracking user actions
- Enhance expense page with role-based access control
- Improve session caching with authorization state management
2025-07-09 10:40:27 -04:00
Matt 2774b4050f Improve mobile responsiveness across expense tracking interface
- Add horizontal margins to modals on mobile devices
- Optimize grid layouts with smaller breakpoints (md→sm)
- Make action buttons full-width on mobile with touch optimization
- Adjust text sizes and spacing for better mobile readability
- Enhance date filter and export controls for mobile interaction
2025-07-04 10:44:42 -04:00
Matt e66d6ad1f2 Add processing fee option to PDF export modal
- Add checkbox to include 5% processing fee in PDF exports
- Install PDF generation dependencies (@pdfme/common, @pdfme/generator, sharp)
- Add server-side expenses API endpoints
- Update PDF options interface to support processing fee toggle
2025-07-04 09:27:43 -04:00
Matt 5cee783ef5 Add expense tracking system with receipt management and currency conversion
- Add expense list and detail views with filtering capabilities
- Implement receipt image viewer and PDF export functionality
- Add currency conversion support with automatic rate updates
- Create API endpoints for expense CRUD operations
- Integrate with NocoDB for expense data persistence
- Add expense menu item to dashboard navigation
2025-07-03 21:29:42 +02:00
Matt 38a08edbfd FEAT: Add documentation for Keycloak session timeout fix and configuration steps 2025-06-17 19:05:04 +02:00
Matt b6e5c21d8a FEAT: Enhance layout and styling in BerthDetailsModal and interest-berth-status for improved readability and visual appeal 2025-06-17 18:14:21 +02:00
Matt 5d614b3dc0 FEAT: Adjust padding and gap in berth status card layout for improved visual spacing 2025-06-17 18:09:45 +02:00
Matt b585daddde FEAT: Enhance berth color handling in dashboard components and improve authentication middleware with caching 2025-06-17 18:05:22 +02:00
Matt 8a4824e6fe FEAT: Enhance interest fetching in InterestDetailsModal and update getBerths and getBerthById to retrieve full details for interested parties 2025-06-17 17:34:29 +02:00
Matt 45f0a3527e FEAT: Remove test-specific berth handler and related functionality 2025-06-17 17:31:07 +02:00
Matt e4f4f0285a FEAT: Update getBerths and getBerthById functions to handle interested parties as counts and fetch linked records 2025-06-17 17:24:04 +02:00
Matt 843205a529 FEAT: Enhance getBerths and test-specific-berth functionality to improve interested parties handling and debugging 2025-06-17 17:04:45 +02:00
Matt d9f359d874 FEAT: Implement debug and test endpoints for fetching and analyzing berth interested parties 2025-06-17 16:49:43 +02:00
Matt d0632b2839 FEAT: Enhance getBerths and getBerthById functions to populate interested parties details 2025-06-17 16:27:32 +02:00
Matt 150f7f9aa9 FEAT: Rename 'Depth' to 'Draft' in Berth model and update related components for consistency 2025-06-17 16:18:29 +02:00
Matt adf226a38a FEAT: Refactor berth API functions to use dedicated utility methods for fetching and updating berths, and add connection test for NocoDB 2025-06-17 16:07:15 +02:00
Matt 0e85cb40bc Replace external berth dashboard with native Vue interface
- Replace iframe embed with full-featured berth status dashboard
- Add BerthDetailsModal and BerthStatusBadge components
- Implement search, filtering, and multiple view modes
- Add berth management API endpoints (get-by-id, update)
- Include measurement conversion utilities and type definitions
- Provide status summaries and visual berth overview
2025-06-17 15:59:39 +02:00
Matt 0b881a2588 FEAT: Correct spelling of 'Documenso' in API utility functions and add connectivity test for Documenso API 2025-06-17 15:17:19 +02:00
Matt 8d378f5b53 FEAT: Enhance authentication system with internal API support, Keycloak connectivity diagnostics, and simplified client implementation 2025-06-17 15:05:41 +02:00
Matt 04ed9a094d FEAT: Implement Keycloak client with circuit breaker and retry logic for improved authentication resilience 2025-06-17 14:50:34 +02:00
Matt d436367ee6 FEAT: Enhance authentication session management with configurable cookie domain and improved token refresh logic 2025-06-16 17:53:43 +02:00
Matt 3a83831a20 FEAT: Implement authenticated internal API call utility to forward cookies and enhance authentication handling 2025-06-15 17:48:40 +02:00
Matt a7df6834d7 FEAT: Migrate authentication system from Directus to Keycloak, implementing token refresh and enhancing session management 2025-06-15 17:37:14 +02:00
Matt d53f4f03f5 REF: Remove unnecessary x-tag headers from API requests in interest-related components 2025-06-15 17:18:24 +02:00
Matt 536e544d04 DEBUG: Add detailed OIDC cookie debugging for file preview issues
- Added logging for OIDC session presence and type detection
- Will help identify why OIDC cookies aren't being sent during file preview requests
- Keycloak login works but file previews fail due to missing OIDC cookie
2025-06-15 17:06:01 +02:00
Matt d45ae31f10 FEAT: Unified Authentication System - Support Both Directus and Keycloak Users
**Problem Solved:**
- File previews failing due to unsupported Directus authentication
- Encrypted OIDC cookies causing JSON parse errors
- Need both Directus and Keycloak users to access same dashboard

**Changes:**
- server/utils/auth.ts: Added Directus token validation alongside OIDC
- server/api/auth/session.ts: Support both auth methods with proper user data
- server/api/auth/logout.ts: Clear appropriate cookies based on auth method

**Authentication Methods Now Supported:**
1. X-tag headers (webhooks/external calls)
2. Directus tokens (existing Directus users)
3. OIDC sessions (Keycloak users, encrypted or plain)

**Result:**
- Both Directus and Keycloak users can access dashboard
- File previews work for all authenticated users
- Proper logout handling for each auth method
- No more JSON parse errors for encrypted OIDC cookies
2025-06-15 17:03:42 +02:00
Matt 7ca77e2dcf FIX: Correct OIDC cookie name mismatch across all auth endpoints
**Root Cause:**
- Auth system was looking for 'keycloak-session' cookies
- But actual OIDC system uses 'nuxt-oidc-auth' cookies
- This caused authentication failures for file previews and other endpoints

**Files Updated:**
- server/utils/auth.ts: Updated to check 'nuxt-oidc-auth' cookie
- server/api/auth/session.ts: Updated cookie name references
- server/api/auth/logout.ts: Updated cookie deletion
- server/api/auth/keycloak/callback.ts: Updated cookie creation

**Result:**
- File previews should now work for authenticated users
- All authentication endpoints now use consistent cookie names
- Both x-tag headers and OIDC sessions work correctly
2025-06-15 16:58:45 +02:00
Matt 6c1a1fa842 DEBUG: Add auth debugging logs to identify file preview auth issue 2025-06-15 16:53:20 +02:00
Matt 4b3f75d4cf FIX: Date format issue for NocoDB PostgreSQL integration 2025-06-15 16:52:26 +02:00