Files
libra/docs/tasks/2-4.md
T
Naser Mansour 0f9d12c3cf Prepare project for pipeline takeover: task tracker, UX doc, CLAUDE.md pointers
Adds docs/tasks/ (16 epics + 102 stories converted to task/subtask files with
statuses.md as the new status source of truth) and docs/ux-design.md
(retrospective design-system reference), and points CLAUDE.md at them.
docs/prd.md and docs/architecture.md are kept as BMAD wrote them; the legacy
docs/stories/, docs/epics/, docs/qa/gates/ and .bmad-core/ stay in place as
historical/traceability records, superseded but not deleted.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-27 22:02:23 +03:00

39 lines
1.6 KiB
Markdown

---
id: 2-4
title: 2-4 Account Lifecycle Management
status: QA Review
date: 2026-09-27
parent: 2
---
## Description
As an admin, I want to deactivate, reactivate, and permanently delete client accounts, So that I can manage the full lifecycle of client relationships. Context: Integrates with: Users table, consultations, timelines, notifications, sessions; Technology: Livewire Volt (class-based), Flux UI modals, Pest tests; Follows pattern: Same admin action patterns as Story 2.1/2.2, soft deactivation via status field, hard deletion with cascade. Full implementation history: docs/stories/story-2.4-account-lifecycle-management.md
## Acceptance Criteria
- [ ] "Deactivate" button on user profile and list
- [ ] Confirmation dialog explaining consequences
- [ ] Effects of deactivation:
- [ ] Visual indicator in user list (grayed out, badge)
- [ ] Audit log entry created
- [ ] "Reactivate" button on deactivated profiles
- [ ] Confirmation dialog
- [ ] Effects of reactivation:
- [ ] Email notification sent to user
- [ ] Audit log entry created
- [ ] "Delete" button (with danger styling)
- [ ] Confirmation dialog with strong warning:
- [ ] Effects of deletion:
- [ ] Audit log entry preserved (for audit trail)
- [ ] No email sent (user no longer exists)
- [ ] "Reset Password" action on user profile
- [ ] Options:
- [ ] Email new credentials to client
- [ ] Force password change on next login (optional) - Not implemented per simplified approach
- [ ] Audit log entry created
- [ ] All actions logged in admin_logs table
- [ ] Bilingual confirmation messages
- [ ] Clear visual states for account status
- [ ] Tests for all lifecycle operations