erp-transportistas-v2/orchestration/00-guidelines/CONTEXTO-PROYECTO.md
Adrian Flores Cortes 37ed0aa919 feat: Initial project structure for ERP Transportistas
Vertical ERP for freight transport and logistics companies.

Includes:
- Project configuration (CLAUDE.md, SIMCO orchestration)
- Backend submodule (NestJS 10.x)
- Frontend submodule (React 18.x + Vite)
- Database submodule (PostgreSQL 15 + PostGIS)
- Requirements documentation (REQ-GIRO-TRANSPORTISTA.md)
- 20 modules defined (MAI/MAE/MAA phases)

Key features:
- Transport orders (OT) management
- Fleet and driver management
- Real-time GPS tracking
- POD (Proof of Delivery)
- CFDI with Carta Porte 3.1 compliance
- Fuel and maintenance control
- Third-party carrier management

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-25 09:53:54 -06:00

129 lines
2.8 KiB
Markdown

# Contexto del Proyecto - ERP Transportistas
**Proyecto:** erp-transportistas
**Tipo:** CONSUMER (Vertical ERP)
**Fecha:** 2026-01-25
---
## Descripcion General
ERP Transportistas es una solucion vertical especializada para empresas de autotransporte de carga, operadores logisticos y 3PL. Hereda la funcionalidad base de erp-core y agrega modulos especificos del giro de transporte.
---
## Posicion en la Jerarquia
```
template-saas (PROVIDER)
|
v
erp-core (INTERMEDIATE)
|
v
erp-transportistas (CONSUMER) <-- ESTE PROYECTO
```
---
## Herencia
### Hereda de:
1. **workspace-v2/orchestration/** - Directivas globales SIMCO
2. **projects/erp-core/** - Modulos base ERP, auth, multi-tenancy
### Exporta a:
- Ninguno (es CONSUMER, no propaga)
---
## Modulos Heredados (22)
| Categoria | Modulos |
|-----------|---------|
| Foundation | auth, users, roles, tenants |
| Core Business | catalogs, settings, financial, inventory, purchasing, sales |
| Extended | audit, notifications, reports, crm, projects |
| SaaS Platform | billing, plans, webhooks, feature_flags |
| IA/Intelligence | ai_integration, whatsapp_business, mcp_server |
---
## Modulos Propios del Giro (20)
### Fase 1 - MAI (15 modulos)
1. MAI-002: Clientes y Tarifas
2. MAI-003: Ordenes de Transporte
3. MAI-004: Planeacion TMS
4. MAI-005: Despacho
5. MAI-006: Tracking
6. MAI-007: POD y Cierre
7. MAI-008: Incidencias
8. MAI-009: Facturacion Transporte
9. MAI-010: Liquidaciones
10. MAI-011: Gestion de Flota
11. MAI-012: Combustible y Gastos
12. MAI-013: Mantenimiento Flota
13. MAI-014: Carriers (Terceros)
14. MAI-015: Portal Cliente
### Fase 2 - MAE (3 modulos)
15. MAE-016: Carta Porte CFDI
16. MAE-017: HOS y Bitacora
17. MAE-018: Reportes y KPIs
### Fase 3 - MAA (2 modulos)
18. MAA-019: Optimizacion Rutas
19. MAA-020: Integraciones EDI
---
## Tecnologias
| Capa | Tecnologia | Version |
|------|------------|---------|
| Backend | NestJS | 10.x |
| Frontend | React | 18.x |
| Database | PostgreSQL + PostGIS | 15+ |
| ORM | TypeORM | 0.3.x |
| Cache | Redis | 7.x |
---
## Base de Datos
- **Nombre:** erp_transportistas_db
- **Schemas:** public, transport, fleet, tracking, fuel, maintenance, carriers, billing, compliance
- **Extension:** PostGIS (para geolocalizacion)
---
## Integraciones Criticas
1. **GPS/Telematica** - Tracking de unidades en tiempo real
2. **PAC (SAT)** - Timbrado CFDI + Carta Porte
3. **Mapas** - Calculo de distancias y ETA
4. **WhatsApp** - Notificaciones a clientes y operadores
---
## Cumplimiento Normativo
- **Carta Porte 3.1** - CFDI obligatorio para transporte
- **NOM-087** - Bitacora de horas de servicio
- **NOM-068** - Condiciones fisico-mecanicas
---
## Estado Actual
- **Progreso:** 5% (proyecto nuevo)
- **DDL:** 0%
- **Backend:** 0%
- **Frontend:** 0%
- **Documentacion:** 100%
---
*Contexto ERP Transportistas - SIMCO v4.0.0*