Commit Graph

83 Commits

Author SHA1 Message Date
Urtzi Alfaro
c07df124fb Improve UI 2025-12-30 14:40:20 +01:00
Urtzi Alfaro
532b057f59 fix demo load 2025-12-25 20:20:16 +01:00
Urtzi Alfaro
bfa5ff0637 Imporve onboarding UI 2025-12-19 13:10:24 +01:00
Urtzi Alfaro
f10a2b92ea Improve onboarding 2025-12-18 13:26:32 +01:00
Urtzi Alfaro
8bfe4f2dd7 Fix Demo enterprise 2025-12-17 13:03:52 +01:00
Urtzi Alfaro
a030bd14c8 demo seed change 2 2025-12-14 11:58:14 +01:00
Urtzi Alfaro
ff830a3415 demo seed change 2025-12-13 23:57:54 +01:00
Urtzi Alfaro
667e6e0404 New alert service 2025-12-05 20:07:01 +01:00
Urtzi Alfaro
9bc048d360 Add whatsapp feature 2025-11-13 16:01:08 +01:00
Claude
2c9d43e887 feat: Improve onboarding wizard UI, UX and dark mode support
This commit implements multiple improvements to the onboarding wizard:

**1. Unified UI Components:**
- Created InfoCard component for consistent "why is important" blocks across all steps
- Created TemplateCard component for consistent template displays
- Both components use global CSS variables for proper dark mode support

**2. Initial Stock Entry Step Improvements:**
- Fixed title/subtitle positioning using unified InfoCard component
- Fixed missing count bug in warning message (now uses {{count}} interpolation)
- Fixed dark mode colors using CSS variables (--color-success, --color-info, etc.)
- Changed next button title from "completar configuración" to "Continuar →"
- Implemented stock creation API call using useAddStock hook
- Products with stock now properly save to backend on step completion

**3. Dark Mode Fixes:**
- Fixed QualitySetupStep: Enhanced button selection visibility with rings and shadows
- Fixed TeamSetupStep: Enhanced role selection visibility with rings and shadows
- Fixed AddressAutocomplete: Replaced all hardcoded colors with CSS variables
- All dropdown results, icons, and hover states now properly adapt to dark mode

**4. Streamlined Wizard Flow:**
- Removed POI Detection step from wizard (step previously added complexity)
- POI detection now runs automatically in background after tenant registration
- Non-blocking approach ensures users aren't delayed by POI detection
- Removed Revision step (setup-review) as it adds no user value
- Completion step is now the final step before dashboard

**5. Backend Updates:**
- Updated onboarding_progress.py to remove poi-detection from ONBOARDING_STEPS
- Updated onboarding_progress.py to remove setup-review from ONBOARDING_STEPS
- Updated step dependencies to reflect streamlined flow
- POI detection documented as automatic background process

All changes maintain backward compatibility and use proper TypeScript types.
2025-11-12 14:48:46 +00:00
Urtzi Alfaro
5783c7ed05 Add POI feature and imporve the overall backend implementation 2025-11-12 15:34:10 +01:00
Urtzi Alfaro
cbe19a3cd1 IMPORVE ONBOARDING STEPS 2025-11-09 09:22:08 +01:00
Claude
4c647f4182 Fix onboarding API dependencies after removing manual path
**Root Cause:**
Frontend removed data-source-choice step and manual path, but backend
still required data-source-choice as dependency for smart-inventory-setup.

This caused: "Cannot complete step smart-inventory-setup: dependencies not met"

**Changes:**

1. **Removed data-source-choice step** (line 48)
   - No longer in ONBOARDING_STEPS list
   - AI-assisted is now the only path

2. **Updated setup dependencies** (line 79)
   - Before: "setup": ["user_registered", "data-source-choice"]
   - After: "setup": ["user_registered", "bakery-type-selection"]
   - Removed dependency on non-existent step

3. **Removed manual path steps**
   - Removed "inventory-setup" from ONBOARDING_STEPS
   - Kept only AI-assisted path steps

4. **Updated suppliers dependencies** (line 87)
   - Now requires "smart-inventory-setup" completion
   - Makes logical sense: need inventory before suppliers

5. **Simplified ML training validation** (lines 278-299)
   - Removed manual path check (inventory-setup)
   - Only validates AI path (smart-inventory-setup)
   - Cleaner logic without dual-path complexity

**Step Order (Updated):**
```
1. user_registered
2. bakery-type-selection
3. setup (tenant creation)
4. smart-inventory-setup (AI inventory)
5. product-categorization
6. initial-stock-entry
7. suppliers-setup
8. recipes-setup (optional)
9. production-processes (optional)
10. quality-setup (optional)
11. team-setup (optional)
12. ml-training
13. setup-review
14. completion
```

**Dependency Chain (Fixed):**
```
smart-inventory-setup → setup → bakery-type-selection → user_registered
(was broken: smart-inventory-setup → setup → data-source-choice [MISSING!])
```

**Files Modified:**
- services/auth/app/api/onboarding_progress.py:42-101,278-299

**Impact:**
 Onboarding steps now work correctly from initial bakery registration
 No more "dependencies not met" errors
 Backend matches frontend architecture
2025-11-07 08:18:39 +00:00
Claude
b22634388d Make backend robust with comprehensive onboarding steps
Backend Changes (services/auth/app/api/onboarding_progress.py):
- Expanded ONBOARDING_STEPS to include all 19 frontend steps
  - Phase 0: user_registered (system)
  - Phase 1: bakery-type-selection, data-source-choice (discovery)
  - Phase 2: setup, smart-inventory-setup, product-categorization, initial-stock-entry (core setup & AI path)
  - Phase 2b: suppliers-setup, inventory-setup, recipes-setup, production-processes (manual path)
  - Phase 3: quality-setup, team-setup (advanced config)
  - Phase 4: ml-training, setup-review, completion (finalization)

- Updated STEP_DEPENDENCIES with granular requirements
  - AI path: smart-inventory-setup → product-categorization → initial-stock-entry
  - Manual path: Independent setup for suppliers, inventory, recipes, processes
  - Flexible ML training: accepts either AI or manual inventory path

- Enhanced ML training validation
  - Supports both AI-assisted path (sales data) and manual inventory path
  - More flexible validation logic for multi-path onboarding

Frontend Changes (UnifiedOnboardingWizard.tsx):
- Fixed auto-complete step name: 'suppliers' → 'suppliers-setup'
- All step IDs now match backend ONBOARDING_STEPS exactly
- Removed temporary step mapping workarounds

Frontend Changes (apiClient.ts):
- Fixed tenant ID requirement warnings for onboarding endpoints
- Added noTenantEndpoints list for user-level endpoints:
  - /auth/me/onboarding (tenant created during onboarding)
  - /auth/me (user profile)
  - /auth/register, /auth/login
- Eliminated false warnings during onboarding flow

This makes the onboarding system fully functional with:
 Backend validates all 19 onboarding steps
 Proper dependency tracking for multi-path onboarding
 No more "Invalid step name" errors
 No more tenant ID warnings for onboarding
 Robust state tracking for complete user journey
2025-11-06 13:38:06 +00:00
Urtzi Alfaro
269d3b5032 Add user delete process 2025-10-31 11:54:19 +01:00
Urtzi Alfaro
36217a2729 Improve the frontend 2 2025-10-29 06:58:05 +01:00
Urtzi Alfaro
858d985c92 Improve the frontend modals 2025-10-27 16:33:26 +01:00
Urtzi Alfaro
61376b7a9f Improve the frontend and fix TODOs 2025-10-24 13:05:04 +02:00
Urtzi Alfaro
b6cb800758 Improve GDPR implementation 2025-10-16 07:28:04 +02:00
Urtzi Alfaro
8f9e9a7edc Add role-based filtering and imporve code 2025-10-15 16:12:49 +02:00
Urtzi Alfaro
7c72f83c51 REFACTOR ALL APIs fix 1 2025-10-07 07:15:07 +02:00
Urtzi Alfaro
38fb98bc27 REFACTOR ALL APIs 2025-10-06 15:27:01 +02:00
Urtzi Alfaro
c9d8d1d071 Fix onboarding process not getting the subcription plan 2025-10-01 21:56:38 +02:00
Urtzi Alfaro
2eeebfc1e0 Fix Alembic issue 2025-10-01 11:24:06 +02:00
Urtzi Alfaro
7cc4b957a5 Fix DB issue 2s 2025-09-30 21:58:10 +02:00
Urtzi Alfaro
ec6bcb4c7d Add migration services 2025-09-30 08:12:45 +02:00
Urtzi Alfaro
befcc126b0 Refactor all main.py 2025-09-29 13:13:12 +02:00
Urtzi Alfaro
4777e59e7a Add base kubernetes support final fix 4 2025-09-29 07:54:25 +02:00
Urtzi Alfaro
222f945466 Add base kubernetes support 2 2025-09-27 12:10:43 +02:00
Urtzi Alfaro
63a3f9c77a Add base kubernetes support 2025-09-27 11:18:13 +02:00
Urtzi Alfaro
dcb3ce441b Improve the inventory page 2025-09-17 16:06:30 +02:00
Urtzi Alfaro
5269a083b6 Imporve the role based forntend protected roles 2025-09-09 07:32:59 +02:00
Urtzi Alfaro
b73f3b4993 Start integrating the onboarding flow with backend 12 2025-09-07 17:25:30 +02:00
Urtzi Alfaro
a11fdfba24 Start integrating the onboarding flow with backend 1 2025-09-03 18:29:56 +02:00
Urtzi Alfaro
c4d4aeb449 Add onboardin steps improvements 2025-08-11 07:01:08 +02:00
Urtzi Alfaro
62ca49d4b8 Improve the design of the frontend 2025-08-08 19:21:23 +02:00
Urtzi Alfaro
488bb3ef93 REFACTOR - Database logic 2025-08-08 09:08:41 +02:00
Urtzi Alfaro
b0d83720fd Fix user delete flow 12 2025-08-03 14:42:33 +02:00
Urtzi Alfaro
b35eb7c875 Fix user delete flow 11 2025-08-03 00:16:31 +02:00
Urtzi Alfaro
a65386e138 Fix user delete flow 10 2025-08-02 23:42:59 +02:00
Urtzi Alfaro
abe74f32f8 Fix user delete flow 9 2025-08-02 23:29:18 +02:00
Urtzi Alfaro
8d1b7c1efb Fix user delete flow 4 2025-08-02 18:38:14 +02:00
Urtzi Alfaro
eedbc2401e Fix user delete flow 3 2025-08-02 18:18:05 +02:00
Urtzi Alfaro
66716c054d Fix user delete flow 2 2025-08-02 17:53:28 +02:00
Urtzi Alfaro
3681429e11 Improve user delete flow 2025-08-02 17:09:53 +02:00
Urtzi Alfaro
277e8bec73 Add user role 2025-08-02 09:41:50 +02:00
Urtzi Alfaro
d4687e6375 Add the initial user admin delete code 2025-08-01 22:20:32 +02:00
Urtzi Alfaro
97ae58fb06 REFACTOR API gateway fix 8 2025-07-26 23:29:57 +02:00
Urtzi Alfaro
1291d05183 REFACTOR API gateway fix 7 2025-07-26 22:03:55 +02:00
Urtzi Alfaro
de3bd5e541 REFACTOR API gateway fix 6 2025-07-26 21:48:53 +02:00