Commit graph

23 commits

Author SHA1 Message Date
fullsizemalt
15e1a8b199 feat(visitor): Implement Digital Badge System
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Added public /badges/:id route with BadgePage component
- Updated VisitorKiosk to display QR code upon check-in
- Backend now returns visitId in check-in response
- Added qrcode.react dependency
2025-12-11 13:51:47 -08:00
fullsizemalt
0a631f462a docs: Add Phase 15 (3D Visualization) to Roadmap
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Added spec for 'Cool 3D Views' using react-three-fiber
- Planned features: 3D volumes, tier stacking, walking mode
2025-12-11 13:30:50 -08:00
fullsizemalt
9cabd54718 docs: Update Roadmap
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Added Phase 14: Facility Monitoring & Security Integration
- Marked Sprint 1 (Infrastructure) as Completed
- Marked Sprint 2 (Integration) as Roadmapped/Future
2025-12-11 13:09:15 -08:00
fullsizemalt
1ef3dc0d80 fix(seed): Adjust Nutrient Management for 16-gal Test Stock
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Updated seed.js task to reflect 16-gallon test stock protocol (scaling factor 0.32)
- Updated Spec 006 with 16-gallon protocol details
- Updated validation targets (EC ~2.9 for Part A, ~1.69 for Part B/PZ)
2025-12-11 12:47:31 -08:00
fullsizemalt
3dad07de03 feat(seed): Add Nutrient Management protocols and Supplies
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Added Front Row Ag 3-2-2 Mixing Task to seed.js
- Added Front Row Ag nutrients and Phoszyme to demo supplies
- Created spec 013 (Facility Monitoring)
- Updated spec 006 (Cultivation) with nutrient protocols
2025-12-11 12:40:03 -08:00
fullsizemalt
4663b0ac86 feat: Navigation refactor with RBAC, DevTools for quick user switching, enhanced seed data
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Refactored navigation with grouped sections (Operations, Cultivation, Analytics, etc.)
- Added RBAC-based navigation filtering by user role
- Created DevTools panel for quick user switching during testing
- Added collapsible sidebar sections on desktop
- Mobile: bottom nav bar (4 items + More) with slide-up sheet
- Enhanced seed data with [DEMO] prefix markers
- Added multiple demo users: Owner, Manager, Cultivator, Worker
- Fixed domain to runfoo.run
- Added Audit Log and SOP Library pages to navigation
- Created usePermissions hook and RoleBadge component
2025-12-11 11:07:22 -08:00
fullsizemalt
558e0ac1e2 feat: Full Spec Kit compliance implementation
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
Photo Management (per specs/photo-management.md):
- Sharp integration for 3-size compression (thumb/medium/full)
- WebP output with 80-90% quality
- Client-side compression with browser-image-compression
- PhotoUpload component with camera/drag-drop support
- Upload API with bulk support and stats endpoint

Testing:
- Backend: Jest tests for all major API endpoints
- Frontend: Vitest tests for utilities and API clients
- CI: Updated Forgejo workflow for test execution

Specs (100% coverage):
- visitor-management.md (Phase 8)
- messaging.md (Phase 9)
- audit-and-documents.md (Phase 10)
- accessibility-i18n.md (Phase 11)
- hardware-integration.md (Phase 12)
- advanced-features.md (Phase 13)

Documentation:
- OpenAPI 3.0 spec (docs/openapi.yaml)
- All endpoints documented with schemas
2025-12-11 09:53:32 -08:00
fullsizemalt
32fd739ccf feat: Complete Phases 8-13 implementation
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
Phase 8: Visitor Management
- Visitor/VisitorLog/AccessZone models
- Check-in/out with badge generation
- Zone occupancy tracking
- Kiosk and management pages

Phase 9: Messaging & Communication
- Announcements with priority levels
- Acknowledgement tracking
- Shift notes for team handoffs
- AnnouncementBanner component

Phase 10: Compliance & Audit Trail
- Immutable AuditLog model
- Document versioning and approval workflow
- Acknowledgement tracking for SOPs
- CSV export for audit logs

Phase 11: Accessibility & i18n
- WCAG 2.1 AA compliance utilities
- react-i18next with EN/ES translations
- User preferences context (theme, font size, etc)
- High contrast and reduced motion support

Phase 12: Hardware Integration
- QR code generation for batches/plants/visitors
- Printable label system
- Visitor badge printing

Phase 13: Advanced Features
- Environmental monitoring (sensors, readings, alerts)
- Financial tracking (transactions, P&L reports)
- AI/ML insights (yield predictions, anomaly detection)
2025-12-11 00:26:25 -08:00
fullsizemalt
e240ec7911 feat(phase2): Implement Phase 2 - Plant Touch Points & IPM
Added PlantTouchPoint and IPMSchedule models. Implemented touch-points and IPM controllers/routes. Updated frontend with Dashboard feed and IPM widgets.
2025-12-09 21:22:47 -08:00
fullsizemalt
17138b2f80 docs: Add roadmap + implementation plan
📋 Documentation:
- ROADMAP.md (complete feature roadmap)
- QUICK-IMPLEMENTATION-PLAN.md (shopping list, touch points, tasks)

⚠️ CRITICAL ISSUE IDENTIFIED:
- ALL pages have hardcoded bg-white (not dark mode compatible)
- Need to fix: Dashboard, Batches, Rooms, Timeclock, Walkthrough
- Font stack reverting to Inter (CSS not syncing properly)

Next: Mass dark mode fix for all pages
2025-12-09 15:05:53 -08:00
fullsizemalt
a5e122de41 docs: Add PWA manifest + App connections checklist
📱 PWA Support:
- Created manifest.json for Android APK
- 777 Wolfpack branding
- Standalone display mode
- Emerald theme color
- Shortcuts to Daily Walkthrough

📋 Documentation:
- APP-CONNECTIONS-CHECKLIST.md (comprehensive)
- All routes verified
- Missing features documented

📦 Inventory Status:
- Full spec exists (inventory-and-materials.md)
- Includes suppliers, shopping lists, lot tracking
- Phase 3 feature (not yet implemented)

Next: Service worker for offline support
2025-12-09 14:54:28 -08:00
fullsizemalt
fd6d36c6de docs: Complete Session Documentation + Photo Management Spec
📋 Final Documentation Package

Created:
- docs/FINAL-SESSION-SUMMARY.md (comprehensive session summary)
- specs/photo-management.md (storage optimization strategy)

Photo Management Strategy:
- Client-side compression (WebP, 80% quality)
- Server-side multi-size generation (thumb/medium/full)
- 85-90% storage reduction (3-5MB → 300-700KB)
- Local storage with daily backups
- ~13.7 GB/year estimated (very manageable)
- 7-year retention for CA compliance

Implementation:
- Sharp for server-side processing
- browser-image-compression for client-side
- 3 sizes: 200px, 800px, 1920px
- WebP format (30-50% smaller than JPEG)

Estimated: 7-11 hours to implement

Status: All specs complete, deployment successful
Team: 777 Wolfpack ready to use system
URL: https://777wolfpack.runfoo.run
2025-12-09 14:34:28 -08:00
fullsizemalt
84ac830a10 fix: Correct import path in walkthroughApi 2025-12-09 14:27:37 -08:00
fullsizemalt
d156569d99 feat: Daily Walkthrough Frontend - Start + Reservoir Checks
🎨 Frontend UI Implementation (Phase 1.5)

📁 Files Created:
- frontend/src/pages/DailyWalkthroughPage.tsx
- frontend/src/components/walkthrough/ReservoirChecklist.tsx

 Features:
- Mobile-first walkthrough start screen
- 777 Wolfpack branding
- Progress tracking
- Visual tank level indicator
- Touch-friendly slider (44px+ targets)
- Auto status detection (OK/LOW/CRITICAL)
- Color-coded status badges
- Notes field
- Photo upload placeholder
- Responsive design (mobile → tablet → desktop)

📱 Mobile Optimizations:
- Large tap targets (56px buttons)
- Visual feedback (active states)
- Bottom navigation on mobile
- Gradient backgrounds
- Backdrop blur effects
- Touch-friendly sliders

🎨 UX Features:
- Step-by-step wizard
- Progress bar
- Tank-by-tank workflow
- Auto-save ready
- Back navigation
- Clear status indicators

⏭️ Next: Irrigation + Plant Health checklists

Status: 40% Frontend Complete
2025-12-09 14:13:38 -08:00
fullsizemalt
e538227458 feat: Daily Walkthrough Backend API Complete
 Backend API Implementation (Phase 1.5)

📁 Files Created:
- backend/src/controllers/walkthrough.controller.ts
- backend/src/routes/walkthrough.routes.ts

🔌 API Endpoints:
- POST   /api/walkthroughs - Start new walkthrough
- GET    /api/walkthroughs - List walkthroughs (with filters)
- GET    /api/walkthroughs/:id - Get walkthrough detail
- POST   /api/walkthroughs/:id/complete - Mark complete
- POST   /api/walkthroughs/:id/reservoir-checks - Add reservoir check
- POST   /api/walkthroughs/:id/irrigation-checks - Add irrigation check
- POST   /api/walkthroughs/:id/plant-health-checks - Add plant health check

 Features:
- Full CRUD for walkthroughs
- Nested check creation
- User authentication required
- Query filters (status, date range, user)
- Includes related data (user, all checks)
- Error handling
- TypeScript types

🔐 Security:
- Requires authentication (userId from JWT)
- User attribution on creation
- Proper error responses

📊 Response Format:
- Includes user details (name, email, role)
- Includes all checks (reservoir, irrigation, plant health)
- Ordered by date (desc)

⏭️ Next: Frontend UI (4-5 hours)

Build:  Successful
2025-12-09 14:10:14 -08:00
fullsizemalt
8105c2f05c feat: Daily Walkthrough Spec + Compliance Audit
🔴 CRITICAL: 777 Wolfpack Team Requirements

 Created:
- specs/daily-walkthrough.md (comprehensive feature spec)
- docs/AUDIT-DAILY-WALKTHROUGH.md (compliance audit)
- docs/SESSION-SUMMARY.md (session summary)

📋 Daily Walkthrough Requirements:
1. Reservoir Checks (veg + flower tanks, levels, photos)
2. Irrigation System Checks (drippers, water flow, nutrients, 4 zones)
3. Plant Health Spot Checks (pests, water/food access, photos)

🏗️ Technical Design:
- 4 new models (DailyWalkthrough, ReservoirCheck, IrrigationCheck, PlantHealthCheck)
- Photo upload support
- Zone-based organization (Veg Up/Down, Flower Up/Down)
- Offline support
- Issue flagging + notifications

📊 Spec Compliance:
-  Aligns with constitution
-  Fits existing architecture
-  Mobile-first ready
- 🔴 Elevated to Phase 1.5 (critical priority)

⏭️ Recommendation: Implement as Phase 1.5 (12-15 hours)

Team: 777 Wolfpack
Priority: CRITICAL - First thing every morning
2025-12-09 14:02:44 -08:00
fullsizemalt
4c0aad0e06 feat: Sprint 2.5 - Mobile-First Foundation
 Implemented:
- Mobile-first Tailwind breakpoints (xs: 375px → 2xl: 1536px)
- Tablet-optimized for cultivation floor (md: 768px primary target)
- Touch-friendly spacing (44px minimum tap targets)
- Mobile-optimized font sizes (16px minimum to prevent iOS zoom)
- Touch-friendly base styles (smooth scrolling, tap highlights)
- Added 777 Wolfpack team logo for splash screen

�� Mobile-First Features:
- Responsive container padding (1rem mobile → 3rem desktop)
- Touch target utilities (touch: 44px, touch-lg: 56px)
- iOS-optimized inputs (prevent zoom, smooth scrolling)
- Webkit touch improvements

🎨 Branding:
- Added 777 Wolfpack logo to /frontend/public/assets/
- Team name: 777 Wolfpack (initial cultivation team users)

⏭️ Next: Mobile navigation + responsive page layouts
2025-12-09 13:55:53 -08:00
fullsizemalt
9dc0586d67 feat: Sprint 2 Phase 1 - Auth Core Complete
 Implemented:
- Password hashing with bcrypt (salt rounds = 10)
- JWT token generation (access 15m, refresh 7d)
- Updated login endpoint to return access + refresh tokens
- Added refresh and logout endpoints
- Updated seed script with hashed passwords
- Added test users for all roles (OWNER, MANAGER, GROWER, STAFF)

📝 Files Added/Modified:
- backend/src/utils/password.ts (NEW)
- backend/src/utils/jwt.ts (NEW)
- backend/src/controllers/auth.controller.ts (UPDATED)
- backend/src/routes/auth.routes.ts (UPDATED)
- backend/prisma/seed.js (UPDATED - now hashes passwords)
- CREDENTIALS.md (UPDATED - all test users documented)

🔐 Test Users:
- admin@runfoo.run (OWNER)
- manager@runfoo.run (MANAGER)
- grower@runfoo.run (GROWER)
- staff@runfoo.run (STAFF)
All passwords: password123

⏭️ Next: Auth middleware + RBAC
2025-12-09 13:52:54 -08:00
fullsizemalt
a9ffd1d5ca fix: Correct email domain from .com to .run
- Updated seed script: admin@runfoo.comadmin@runfoo.run
- Updated all documentation to reflect correct email
- Need to re-seed database on deployment
2025-12-09 13:46:25 -08:00
fullsizemalt
7901325974 docs: Complete Sprint 1 - Backend health check fixed
 Sprint 1 Complete:
- Changed health check from curl to wget (alpine compatible)
- Changed localhost to 127.0.0.1 (fixes DNS issues with Tailscale/Docker)
- Backend now shows (healthy) status
- Added CREDENTIALS.md with login info
- Documented solution in SPRINT-1-HEALTHCHECK.md

Login credentials:
- Email: admin@runfoo.com
- Password: password123
- URL: https://777wolfpack.runfoo.run
2025-12-09 13:45:01 -08:00
fullsizemalt
d2c3e67e40 fix: Change health check from curl to wget for alpine compatibility
- Backend container uses node:20-alpine which doesn't include curl
- wget is available by default in alpine
- Health check endpoint is working, just the command was wrong
- Also added Sprint 1 documentation and credentials file
2025-12-09 13:39:43 -08:00
fullsizemalt
28d8e9e4a2 docs: Add agent-optimized debugging workflows for DNS/Routing
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
2025-12-09 08:54:51 -08:00
fullsizemalt
da7729d6e4 Initial commit: Spec Kit foundation complete
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s
- Constitution and project spec (spec.yml)
- 7 comprehensive feature specs (tasks, batches, labor, compliance, inventory, integrations, comms)
- Phase 1 implementation plan (6-week roadmap)
- Week 1 task breakdown (15 concrete tasks)
- Architecture and compliance documentation
- Backend and frontend setup guides
- Deployment guide for nexus-vector
- CI/CD workflows (Forgejo Actions)
- Quick start guide for developers

Project is ready for implementation with:
- Automated testing on every push
- Automatic deployment to nexus-vector on push to main
- Database migrations handled automatically
- Health checks and monitoring

Stack: TypeScript, Fastify, React, Vite, PostgreSQL, Prisma, Docker
2025-12-08 23:54:12 -08:00