GuideOpen

User List

Route: /users Module: User Management Generated: 2026-03-17

User List

Route: /users Module: User Management Generated: 2026-03-17

Overview

Displays all system users in a searchable, paginated table. Supports creating, editing, and deleting users. Only ADMIN and MANAGER roles can access this page.

Layout

  • Top bar: Search input + "Create User" button
  • Main area: Data table with pagination
  • Modal: Create/Edit user form (triggered by buttons)

Fields

Search Filters

FieldTypeRequiredOptionsDefaultNotes
KeywordText inputNo——Searches name and email
RoleSelect dropdownNoAdmin, Manager, UserAllFilters by role
StatusSelect dropdownNoActive, Inactive, SuspendedAllFilters by status

Data Table

ColumnFormatSortableFilterableNotes
NameTextYesNoFull name
EmailText (link)YesNoClickable → opens detail
RoleBadgeNoYesColor-coded by role
StatusBadgeNoYesGreen=active, Red=suspended
CreatedDate (YYYY-MM-DD)YesNo—
ActionsButtonsNoNoEdit, Delete

Actions

ButtonVisibilityBehavior
Create UserADMIN, MANAGEROpens create modal
EditADMIN, MANAGEROpens edit modal with prefilled data
DeleteADMIN onlyConfirmation dialog → soft delete

Interactions

Page Load

  • Fetches first page of users via GET /api/users?page=1&size=20
  • Default sort: created_at descending

Search

  • Trigger: User types in search field (300ms debounce)
  • Behavior: Re-fetches users with keyword param, resets to page 1
  • Special rules: Minimum 2 characters to trigger search

Create User

  • Trigger: Click "Create User" button
  • Modal content: Name (required, max 50), Email (required, email format), Role (required, select), Status (default: Active)
  • Validation: Name required + max length, Email required + format check
  • API: POST /api/users with form data
  • On success: Toast "User created", close modal, refresh list
  • On failure: Show API error below form

Delete User

  • Trigger: Click "Delete" button on row
  • Behavior: Confirmation dialog "Are you sure you want to delete {name}?"
  • API: DELETE /api/users/:id
  • On success: Toast "User deleted", refresh list

API Dependencies

APIMethodPathTriggerNotes
List usersGET/api/usersLoad, search, paginateParams: page, size, keyword, role, status
Create userPOST/api/usersSubmit create formBody: name, email, role
Delete userDELETE/api/users/:idConfirm delete—

Page Relationships

  • From: Dashboard (click "View Users" link)
  • To: User Detail (click email or row)
  • Data coupling: Creating/deleting a user triggers dashboard stats refresh

Source: https://github.com/alirezarezvani/claude-skills/blob/main/product-team/code-to-prd/skills/code-to-prd/expected_outputs/sample-page-user-list.md

Author: alirezarezvani, Alireza Rezvani skills and agents. License: MIT.

Shown here with formatting for the web. Keep the author and license notice when you reuse it.

Related entries

There are more like this in the members library

The Codex library holds 7,009 entries. Members can search all of them by meaning and read every one in full.