Skip to content

MongocampRoles ​

Full CRUD table for managing roles — create, edit (admin flag, collection grants), and delete. Includes a server-side debounced search input and sortable column headers. The key icon on each row links to the grant management page.

Usage ​

vue
<template>
  <MongocampRoles grants-path="/secured/admin/roles" />
</template>

Props ​

PropTypeDefaultDescription
grantsPathstring/secured/admin/rolesBase path the key icon links to: <grantsPath>/<roleName>

Behavior ​

  • List — fetched via useMongocampAdmin().listRoles(filter), debounced 300ms on the search input.
  • Add / Edit — name, isAdmin flag.
  • Delete — confirmation modal before calling deleteRole.
  • Grant management itself lives in MongocampRoleGrants, reached via the key icon.

Released under the MIT License.