Cien ERP Backend Docs

Developer & Admin Documentation

This guide explains how to work with the Cien ERP backend: authentication & tenancy, IT Support, Document Workflow, finance modules, notifications, and integrations. Use the sidebar to jump between modules, and follow the step‑by‑step checklists.

Backend: Laravel Multi‑tenant MySQL Roles & Permissions aware

Overview & Core Concepts

Cien ERP is a multi‑tenant Laravel application. Each company (tenant) has isolated data, with role‑based access control layered on top of modules such as IT Support, Document Workflow, Accounting, CRM, and more.

Architecture

Laravel + MySQL backend with AdminLTE / Tailwind UI. Tenants are linked to users; every request inside the app passes through tenant and tenant.access middleware.

Roles & Permissions

Fine‑grained permissions per module (e.g. it-support.tickets.view, documents.verify, documents.approve) plus tenant and system admins.

Modules

IT Support, Document Workflow System, Accounting, POS, Inventory, CRM, HR, Call Center, Marketing automation, and more.

  • Start from the landing page, register a tenant, and log in to the dashboard.
  • Assign roles and permissions via Settings → Roles & Permissions.
  • Enable required integrations under Settings → Integration Keys.

Authentication & Tenancy

Access to backend modules is guarded by Laravel auth, email verification, and tenant middleware. Public routes (like this documentation and careers) do not require authentication.

Login Flow

  • User logs in via /login with verified email.
  • System checks is_banned and is_approved flags.
  • On success, user is redirected to Dashboard.

Tenant Isolation

  • Each user is attached to a tenant_id (except some system admins).
  • Core models (Documents, Tickets, Incidents, etc.) are scoped by tenant_id.
  • System admins can operate across tenants where required.
Middleware: auth, verified.nonadmins, tenant, tenant.access

IT Support Module

The IT Support area centralizes Tickets, Incidents, Service Requests, Assets, Problems, Change Requests, and a Knowledge Base. All routes are under the /it-support prefix.

Tickets & Requests

  • Navigate to IT Support → Tickets to raise or manage support cases.
  • Use Incidents for unplanned outages and Service Requests for standard changes.
  • Link Tickets to Assets, Problems, and Change Requests for full traceability.

Technicians & Requesters

  • Maintain people records from IT Support → Requesters / Technicians.
  • Assign tickets or incidents to technicians based on skills or queues.
  • Use Problems & Change Requests for root cause and planned remediation.

Knowledge Base

  • Document fixes and SOPs in Knowledge Base articles.
  • Relate KB articles to Problems and Incidents for faster resolution.
  • Share articles internally per tenant.

Document Workflow System

The Document Workflow module manages document upload, verification, approval, and archival with full version history and access control.

Lifecycle Overview

  1. Upload – Staff A uploads a document (initial status DRAFT).
  2. Verification – Staff B moves it to the verification queue and either verifies or rejects.
  3. Approval – Staff C approves (status ARCHIVED, locked) or rejects.
  4. Archive – Approved documents exit active queues and become read‑only.

Audit Trail & Versioning

  • All actions (upload, update, status change, share) write entries to Document History.
  • Each history record tracks version, actor, timestamps, and field‑level changes.
  • Inline comments are stored with workflow decisions (verification / approval).

Queues & Search

  • Use Documents → Verification Queue to see items in review.
  • Use Documents → Approval Queue for Staff C approval workload.
  • Filter by name/description and workflow status; preview image/PDF files inline with zoom controls.
Locked when archived View without download Full history & comments

Accounting, POS & Inventory

Cien ERP ships with integrated finance, POS, and stock management. These modules are tenant‑scoped and permission‑driven, and can be combined with logistics and CRM modules.

Core Accounting

  • Use Accounting → Transactions / General Ledger for double‑entry posting.
  • Manage AR/AP via Accounts Receivable / Accounts Payable.
  • Generate Profit & Loss, Balance Sheet, and Cash Flow under Financial Statements.

POS & Sales

  • Sales are captured in the POS module with options for card payments (e.g. Paystack).
  • Supports held sales, returns, and receipt printing.
  • Integrates with inventory and accounting for automatic stock and ledger updates.

Inventory

  • Manage products, items, stock movements, and adjustments from the Inventory module.
  • Use alerts and physical stock takes to keep quantities accurate.

Notifications & Webhooks

The platform can send in‑app notifications and trigger external webhooks for events such as shipments, marketing workflows, and call center events.

In‑App Notifications

  • Users receive notifications via the bell icon in the top navigation.
  • Unread counts auto‑refresh; details are shown in a dropdown and in the notifications page.

Webhooks

  • Inbound webhooks (e.g. call‑center providers) hit public endpoints under /call-center/webhooks.
  • Outbound marketing/webhooks are configured in Marketing → Webhooks.

Integration Keys & External Services

Instead of editing .env directly, system administrators can manage integration keys in the UI using Settings → Integration Keys. Keys are stored in the database and support separate test and live configurations.

Managing Keys

  1. Log in as a system admin and go to Settings → Integration Keys.
  2. Select a provider (Paystack, SendGrid, EasyPost, Shippo, etc.).
  3. Paste your Test and Live keys in the corresponding panels.
  4. Toggle Active for the environments you want to use.

Test vs Live

  • The application maps Laravel APP_ENV to the correct test/live configuration.
  • Non‑production environments use test keys; production uses live keys.
Stored in DB System admin only

Support & Troubleshooting

When something does not behave as expected, use these steps to quickly identify and resolve issues.

Common Checks

  • Confirm the user has the correct role and permission for the module.
  • Verify the tenant is active and not past due on subscription.
  • Check any relevant integration keys are present and active.

Where to Look in the UI

  • Permissions issues → Settings → Roles & Permissions.
  • Payment/integration issues → Settings → Integration Keys or Billing.
  • IT Support behaviour → relevant IT Support sub‑module (Tickets, Incidents, Problems, etc.).