Understanding Portfolio Structure
Portfolio items are linked to:- Users (primary) - Each user has their own portfolio
- Artists (fallback) - For backward compatibility with older items
- Sessions (optional) - Link work to specific appointments
- Clients (optional) - Associate work with client records
The system automatically uses the user_id when available, falling back to artist_id for legacy items.
Selecting a User Portfolio
Adding Portfolio Images
- Session ID
- Date
- Client name
Linking portfolio items to sessions helps track which work belongs to which client and appointment.
Viewing Portfolio Items
Gallery View
Portfolio items are displayed as cards in a flowing grid:- Thumbnail - Image scaled to 260px height
- Date - Creation date in YYYY-MM-DD format
- Hover effect - Border brightens on hover
- Drop shadow - Subtle depth effect
Item Details
Click any portfolio card to open the detail dialog showing:- Full-size image - Up to 640px wide
- Fecha - Creation date
- Artista - Artist name
- Sesión - Session ID, status, and price (if linked)
- Cliente - Client name (if linked)
- Transacción - Transaction details (if paid)
- Notas - Caption or notes field
The detail dialog is draggable. Click and hold the background to reposition it.
Filtering Portfolio Items
The toolbar provides several filter options:Style Filter
- Estilo: Todos - All styles
- Filters by the
stylefield if populated
Body Area Filter
- Zona: Todas - All body areas
- Filters by the
body_areafield if populated
Color Mode Filter
- Color: Todos - All items
- Color - Color tattoos only
- B&N - Black and gray only
State Filter
- Estado: Todos - All items
- Fresh - Fresh tattoo photos
- Healed - Healed tattoo photos
Sorting
- Más recientes - Newest first (default)
- Más antiguos - Oldest first
Portfolio Storage
Directory Structure
Legacy Compatibility
Older installations stored avatars inassets/. The system automatically:
- Checks the new data directory first
- Falls back to legacy location if needed
- Migrates files when accessed
All portfolio data is stored locally, giving you full control and no cloud dependencies.
Portfolio Metadata
Each portfolio item can store:- path - Full file path (required)
- user_id - Owner user ID (preferred)
- artist_id - Artist ID (fallback)
- session_id - Linked session
- client_id - Associated client
- transaction_id - Payment record
- style - Tattoo style
- body_area - Body placement
- color_mode - “color” or “bn”
- fresh_or_healed - “fresh” or “healed”
- caption - Notes or description
- created_at - Upload timestamp
User Colors
Artists have color-coded portfolios:- Color bar - Top accent on user cards
- Role chip - Border matches artist color
- Avatar dot - Indicator dot in artist color
artist_colors.jsonby artist_id (key as string)- Fallback color palette based on ID modulo 10
Permissions
Portfolio access:- All users can view portfolios
- Users can upload to their own portfolio
- Admins can upload to any portfolio
Best Practices
High Quality Images
Upload high-resolution photos for the best portfolio presentation.
Link to Sessions
Always link portfolio items to sessions when possible for better organization.
Regular Updates
Add fresh work regularly to keep portfolios current and impressive.
Proper Attribution
Ensure each piece is uploaded to the correct artist’s portfolio.
Troubleshooting
Upload fails with no error
Upload fails with no error
Check that the uploads/portfolios directory is writable and has sufficient disk space.
Image not displaying
Image not displaying
Verify the file still exists at the stored path. The system uses absolute paths.
Session link dialog doesn't appear
Session link dialog doesn't appear
This only shows for users with role=“artist” and a valid artist_id. Other user types upload directly.
Count not updating
Count not updating
The count badge refreshes after successful uploads. Try reloading the page if it seems stuck.