Architecture at a glance

An Ember Octane back office talking JSON:API to a Laravel backend. Three things decide what a user sees: their staff level, their active centre’s modules, and the state of the record in front of them.

Boot sequence

sequenceDiagram
    autonumber
    participant B as Browser
    participant A as application route
    participant C as config.json
    participant I as translations
    participant S as auth service
    participant N as navbar
    B->>A: load app
    A->>C: getJSON config.json
    C-->>A: api host, theme, title, pusher
    A->>I: load en (+ es/pt from browser)
    A->>S: load current user
    alt no session
        S-->>B: redirect to user.login
    else session
        S-->>A: user, centres, dashboards
        A->>N: build menu (level x modules x abilities)
        N-->>B: desktop with home dashboard
    end

See Runtime environment & white-label boot, Back-office interface language, Staff login, Desktop (home dashboard).

Access decision

flowchart TD
    U[Staff member] --> L{Level in ability roles?}
    L -- no --> H1[Hidden from menu + route rejected]
    L -- yes --> M{Centre has module?}
    M -- no --> H1
    M -- yes --> R{Record state allows action?}
    R -- no --> H2[Row action hidden]
    R -- yes --> OK[Action available]
    classDef stop fill:#f7e6e2,stroke:#9a2d1c,color:#6e1f13
    classDef go fill:#e3f1ea,stroke:#0d6b42,color:#0d4a2e
    class H1,H2 stop
    class OK go

See Role & module permission layer and Permission Matrix.

Customer data flows

flowchart LR
    subgraph In[Ways customers get in]
      APP[Mobile app / web registration]
      DESK[Desk: customer form]
      CSV[CSV import]
      PACV[PAC Virtual receipt upload + OCR]
    end
    subgraph Core[CRM]
      USERS[(Customers)]
      SEG[Segments]
      RCPT[Receipt queue]
    end
    subgraph Out[What uses them]
      MAIL[Email campaigns]
      PUSH[Push notifications]
      PROP[Proposals]
      LOY[Raffles · stamps · rewards · vouchers]
      DASH[Dashboards]
      EXP[Exports by email]
    end
    APP --> USERS
    DESK --> USERS
    CSV --> USERS
    PACV --> RCPT --> LOY
    USERS --> SEG
    SEG --> MAIL & PUSH & PROP & LOY
    USERS --> DASH & EXP

Tenant operations flow (intranet)

flowchart LR
    STORE[Store user] -->|daily sales / XLSX / SAFT-E| SALES[Sales month]
    SALES -->|close| MGMT[Centre management]
    MGMT -->|validate| VALID[Validated month]
    MGMT -->|reject + communication| STORE
    VALID --> YEAR[Annual statement]
    VALID --> YARDI[(Yardi)]
    FOOT[Footfall entry] --> YARDI
    MGMT -->|communications & files| STORE