Expand MokoWaaS+ERP into full ERP offering — Joomla-native CMS + ERP platform #192
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Expand MokoWaaS into a full-featured Joomla-native CRM platform, using Dolibarr's module ecosystem as design inspiration (not integration). All CRM functionality is built natively in Joomla with its own database tables and logic. Joomla Contacts serves as the base contact layer, extended with customer/vendor roles, deals pipeline, and activity tracking.
No external ERP dependency. Dolibarr is the blueprint, MokoWaaS is the product.
Architecture: Joomla-Native CRM
Data Model
Joomla's built-in
#__contact_detailsremains the contact record. CRM-specific data lives in dedicated MokoWaaS tables that reference contact IDs.New Database Tables
#__mokowaas_crm_roles— Links a Joomla contact to a CRM roleidcontact_id#__contact_details.idrolestatuscodecredit_limitpayment_terms_daysnotescreatedmodified#__mokowaas_crm_pipeline_stages— Configurable deal pipeline stagesidtitlealiasprobabilityorderingcolorpublished#__mokowaas_crm_deals— Sales pipeline dealsidtitlecontact_id#__contact_details.idstage_id#__mokowaas_crm_pipeline_stages.idvaluecurrencyprobabilityexpected_closeassigned_tostatuslost_reasonnotescreatedmodifiedclosed#__mokowaas_crm_activities— Activity log per contact/dealidcontact_id#__contact_details.iddeal_id#__mokowaas_crm_deals.id(nullable)typesubjectbodydue_datecompleteduser_idcreatedContact Categories → CRM Roles
Joomla Contact categories map to CRM roles:
role = 'customer'role = 'vendor'role = 'prospect'This mirrors Dolibarr's dual-flag thirdparty model but uses Joomla's native category system.
Implementation Plan
Phase 1: CRM Foundation — Contact Roles & Pipeline
Goal: Extend Joomla Contacts with CRM roles, deals pipeline, and activity tracking
New Extension:
plg_system_mokowaas_crmcrm_roles,crm_pipeline_stages,crm_deals,crm_activitiesonContentAfterSaveoncom_contact→ auto-create CRM role based on contact categoryonContentBeforeDeleteoncom_contact→ cascade cleanup of CRM dataModifications to
com_mokowaasNew REST API Routes (
plg_webservices_mokowaas_crm)GET/POST /v1/mokowaas/crm/roles— List/assign CRM rolesGET/POST/PUT /v1/mokowaas/crm/deals— CRUD dealsGET/POST /v1/mokowaas/crm/activities— CRUD activitiesGET /v1/mokowaas/crm/pipeline— Pipeline summary with stage counts and valuesPhase 2: Product Catalog & Shopping Cart
Goal: Native Joomla shopping cart component
New Extension:
com_mokoshopcrm_products,crm_orders,crm_order_items,crm_cartPhase 3: Invoicing & Billing
Goal: Native invoicing tied to CRM contacts and orders
crm_invoices,crm_invoice_items,crm_paymentsPhase 4: Point of Sale
Goal: Touch-screen POS for in-person sales
Phase 5: Inventory & Stock Management
Goal: Warehouse and stock tracking
crm_warehouses,crm_stock_movementsPhase 6: HRM & Projects
Goal: Employee and project management as opt-in features
Phase 7: Marketing & Bulk Mail
Goal: Marketing campaigns from CRM contact base
Extensions Summary
New Extensions
plg_system_mokowaas_crmplg_webservices_mokowaas_crmcom_mokoshopModified Extensions
com_mokowaasmod_mokowaas_cpanelplg_system_mokowaasplg_system_mokowaas_monitorpkg_mokowaas.xmlRemoved from Plan— No Dolibarr-side module neededMokoDoliJoomlaDolibarr REST API integration— All native JoomlaWebhook sync— No external system to sync withDesign Inspiration from Dolibarr
llx_societe(thirdparty with dual customer/vendor flag)#__mokowaas_crm_roles(multiple roles per Joomla contact)llx_socpeople(contacts linked to thirdparties)#__contact_details(native, no duplication)#__mokowaas_crm_dealswith configurable pipeline stagescomm/mailingcom_mokoshopwith inventory tables (Phases 2 & 5)Related Issues
Branch created:
feature/192-expand-mokowaas-into-full-crm-offering-wExtension Breakdown: New vs. Modified
New Extensions
plg_system_mokowaas_crmcom_mokoshopplg_webservices_mokowaas_crmMokoDoliJoomlaModifications to Existing Extensions
plg_system_mokowaas(core)plg_system_mokowaas_monitorcom_mokowaasmod_mokowaas_cpanelpkg_mokowaas.xmlplg_system_mokowaas_crmandplg_webservices_mokowaas_crmas child extensionsMokoDoliJoomlafunctionality or vice versaArchitecture Pattern
Follows MokoWaaS convention of one plugin per concern:
com_mokoshopis a separate component (not insidecom_mokowaas) because it has frontend site views (product listing, product detail, cart, checkout, order history) that are customer-facing, whereascom_mokowaasis admin-only.Architecture Update: Joomla-Native CRM
Revised approach: This is NOT a Dolibarr integration. Dolibarr serves as inspiration/blueprint for feature design, but the CRM is built natively in Joomla with its own database tables and logic.
This means:
— Not neededMokoDoliJoomlaDolibarr REST API integration— Not neededWebhook sync— Not neededplg_system_mokowaas_crmbecomes the native CRM engine, not a sync bridgecom_mokoshopremains as a native Joomla shopping cart componentArchitecture Decision: Use Joomla Articles for Product/Service Descriptions
Instead of storing rich-text descriptions in CRM product tables, reference Joomla
#__content(articles) for product and service descriptions. This reduces table bloat and leverages Joomla's existing content infrastructure.Pattern
Benefits
#__contentHow It Works
article_idlinks to the full description in#__contentTrade-off
com_content— but MokoWaaS IS Joomla, so this is a feature not a cost#__content— but Joomla's content table is well-indexedSub-Issues
Expand MokoWaaS into full CRM offering with Dolibarr module suiteto Expand MokoWaaS+ERP into full ERP offering — Joomla-native CMS + ERP platformUpdate: Full customer-facing frontend portal for ERP
The ERP isn't admin-only — it needs a complete frontend customer portal where logged-in clients can self-service. This is a Joomla site-side component view set, not just backend admin.
Customer Portal Views
com_mokoshop)Access Control
Implementation
com_mokowaas(or newcom_mokowaas_portalif cleaner separation needed)Update: Ticket system integration in customer portal
The existing MokoWaaS helpdesk (
#__mokowaas_tickets,#__mokowaas_ticket_replies) is already built — the customer portal just needs frontend views that interface into it:#__mokowaas_tickets)#__mokowaas_ticket_replies#__mokowaas_ticket_categoriesNo new tables needed — this is purely frontend views on top of the existing helpdesk schema.
Completed — Code distributed to dedicated repos
The ERP feature branch (
feature/192-expand-mokowaas-into-full-erp-offering) has been closed and deleted. All code has been distributed across 8 dedicated repos as standalone licensed Joomla packages:Total: ~260 files, 69 tables, 9 repos.
MokoWaaS base remains lean — CMS, firewall, tenant, health, helpdesk only. No ERP code in the base package.