How rafaelm229/moura-solar works
Moura Solar is an integrated solar-project CRM and operations platform. Users work through a web interface backed by a NestJS API: the documented business stages span customer/opportunity management, design and sizing, proposals and contracts, finance and procurement, engineering and installation, then after-sales support. Identity and permissions govern access across these capabilities. The README describes the integrated process, but most feature implementations were not sampled; dashed links mark documented or plausible connections without source-level relationship evidence.
Main entry points: prisma.service.ts PostgreSQL data · proposal.service.ts Proposal generation · commercial.service.ts Customers and opportunities · design.service.ts Sizing and costs
Components 25
Identity and access
- Identity screens
apps/web/src/features/identity - API client
apps/web/src/features/identity/client.ts - Authentication and RBAC
apps/api/src/identity/auth.service.ts - Permission guard
apps/api/src/identity/identity.guard.ts
Commercial journey
- CRM workspace
apps/web/src/features/commercial - Customers and opportunities
apps/api/src/commercial/commercial.service.ts - Solar design
apps/web/src/features/design - Sizing and costs
apps/api/src/design/design.service.ts - Proposals
apps/web/src/features/proposal/proposals.tsx - Proposal generation
apps/api/src/proposal/proposal.service.ts - Contracts
apps/web/src/features/contract/contracts.tsx - Contract management
apps/api/src/contract/contract.service.ts
Project delivery
- Engineering workspace
apps/web/src/features/engineering/engineering.tsx - Engineering and installation
apps/api/src/engineering/engineering.service.ts - After-sales workspace
apps/web/src/features/after-sales/after-sales.tsx - Support and monitoring
apps/api/src/after-sales/after-sales.service.ts
Operations and governance
- Financial workspace
apps/web/src/features/financial/financial.tsx - Financial governance
apps/api/src/financial/financial.service.ts - Inventory workspace
apps/web/src/features/inventory/inventory.tsx - Inventory and purchasing
apps/api/src/inventory/inventory.service.ts - Automation console
apps/web/src/features/automations/automations.tsx - Versioned automations
apps/api/src/automations/automations.service.ts - PostgreSQL data
apps/api/src/database/prisma.service.ts - S3 or MinIO files
apps/api/src/proposal/storage.service.ts
Other components
- Platform user
Connections 39
- Platform user → Identity screens: signs in
- Platform user → CRM workspace: manages customers
README.md - Platform user → Solar design: designs systems
README.md - Platform user → Proposals: prepares proposals
README.md - Platform user → Contracts: manages contracts
README.md - Platform user → Financial workspace: reviews finances
README.md - Platform user → Inventory workspace: manages stock
README.md - Platform user → Engineering workspace: runs projects
README.md - Platform user → After-sales workspace: handles support
README.md - Platform user → Automation console: configures rules
README.md - Identity screens → API client: uses
apps/web/src/features/identity/sessions.tsx - API client → Authentication and RBAC: authenticates
- Authentication and RBAC → Permission guard: provides context
apps/api/src/identity/identity.guard.ts - Permission guard → Customers and opportunities: guards access
- Permission guard → Engineering and installation: guards access
apps/api/src/engineering/engineering.controller.ts - CRM workspace → Customers and opportunities: calls API
- Customers and opportunities → PostgreSQL data: reads and writes
- Solar design → Sizing and costs: calls API
- Sizing and costs → PostgreSQL data: reads and writes
- Proposals → Proposal generation: calls API
- Proposal generation → PostgreSQL data: reads and writes
- Proposal generation → S3 or MinIO files: stores documents
- Contracts → Contract management: calls API
- Contract management → PostgreSQL data: reads and writes
apps/api/src/contract/contract.service.ts - Financial workspace → Financial governance: calls API
- Financial governance → PostgreSQL data: reads and writes
- Inventory workspace → Inventory and purchasing: calls API
- Inventory and purchasing → PostgreSQL data: reads and writes
- Engineering workspace → Engineering and installation: calls API
apps/web/src/features/engineering/engineering.tsx - Engineering and installation → PostgreSQL data: reads and writes
apps/api/src/engineering/engineering.service.ts - After-sales workspace → Support and monitoring: calls API
- Support and monitoring → PostgreSQL data: reads and writes
apps/api/src/after-sales/after-sales.service.ts - Automation console → Versioned automations: calls API
- Versioned automations → PostgreSQL data: reads and writes
apps/api/src/automations/automations.service.ts - Customers and opportunities → Sizing and costs: advances journey
README.md - Sizing and costs → Proposal generation: supports proposals
README.md - Proposal generation → Contract management: leads to contracts
README.md - Contract management → Financial governance: gates finance
README.md - Engineering and installation → Support and monitoring: continues to support
README.md