Warehouse Floor Plan Module
SVG-based zone layout visualization and management.
Features
- Admin-only floor plan editor with SVG upload
- Interactive zone drawing and editing (rectangles, polygons)
- Real-time driver overlay with GPS mapping
- Heatmap visualization based on analytics
- Read-only viewer for workers with pick route highlighting
- Pan & zoom functionality
- Export/import JSON for floor plan backup
- Integration with Pick & Pack for route visualization
Permissions
- Admin: Full access (editor)
- Worker: Read-only access (viewer)
- Driver: No access
Database Schema
Tables
floorplans: Floor plan master data with SVG contentfloorplan_zones: Zone shapes and positions on floor plan
Key Functions
createFloorplan(): Create new floor planupdateFloorplan(): Update floor plancreateZoneFromRect(): Create zone from rectangleupdateZoneShape(): Update zone shapegetFloorplanWithZones(): Get floor plan with zonescomputeHeatmap(): Compute heatmap valuesmapGeoToSvg(): Map GPS coordinates to SVG coordinates
Integration
- Pick & Pack: Highlights pick route on floor plan
- Driver Locations: Shows real-time driver positions
- Safety: Shows safety risk overlay
- Hazard Mapping (Phase 3): Predictive safety risk heat map with smooth gradients
- Equipment Tracking: Shows equipment positions
Hazard Mapping (Phase 3)
Visual risk overlay integrated with warehouse floor plans.
Features:
- Automatic projection of predictive scores to floor plan zones
- Smooth color gradients (Green → Yellow → Orange → Red)
- Interactive tooltips with risk details
- Manual hazard marking for Safety Officers
- Threshold indicators for critical zones
Color Scheme:
- Green (0-30): Low risk
- Yellow (30-50): Medium risk
- Orange (50-70): High risk
- Red (70-100): Critical risk