Configuration · Staff member list, deletion & restore

Lists back-office users with name, email, level and status, and supports both deleting and restoring an account — so deletion is reversible rather than destructive.

AreaConfiguration
Routesconfiguration.staff-members · configuration.staff-members.index
Centre modulesalways available
Staff levelsper staff-member ability; creation is further limited by each level’s creators list
Modelscenter · staff-member
UI labeltitle.header.configuration.staff-members / menu.navbar.staff.show
Coverage3 use cases · 1 happy · 3 failure

How it works

The restore action alongside delete is the notable part: deactivated accounts can be brought back, which matters for seasonal staff. Who may create whom is encoded per level in enums/staff-levels via a creators array — e.g. root can only be created by root, storeManager has an empty creators list so it cannot be created from the UI at all, and most other levels are creatable by admin and manager. Both actions throw TypeError when handed an invalid record.

Use cases

Why someone opens this (3)

  • Onboarding and offboarding centre staff.
  • Reactivating a seasonal employee’s account for the next campaign.
  • Auditing who has back-office access and at what level.

Path map

flowchart LR
    F(["Staff member list, deletion and restore"]):::feat
    F --> H1["Account deactivated and restored"]:::ok
    F -.-> X1["Invalid record"]:::bad
    F -.-> X2["Level not creatable"]:::bad
    F -.-> X3["Delete/restore rejected"]:::bad
    classDef feat fill:#566066,stroke:#566066,color:#ffffff,font-weight:bold
    classDef ok fill:#e3f1ea,stroke:#0d6b42,color:#0d4a2e
    classDef bad fill:#f7e6e2,stroke:#9a2d1c,color:#6e1f13

Happy paths

Account deactivated and restored

  1. Admin deletes a leaver’s account; the row moves to the inactive status.
  2. Months later the person returns and the admin clicks restore.
  3. The account is reactivated with its previous level and scope.

Failure paths

QA checklist

Tick these off while regression-testing this feature. The boxes are plain Markdown, so progress is visible in git diffs.

  • ✅ Account deactivated and restored
  • ⛔ Invalid record
  • ⛔ Level not creatable
  • ⛔ Delete/restore rejected

Implementation


Generated from doc/feature-inventory.json · id config-staff-list · commit 276788ca6