feat(admin): add Admin module with moderation, user mgmt, and dashboard

- Commands: ApproveListing, RejectListing, BanUser, AdjustSubscription
- Queries: GetModerationQueue, GetDashboardStats, GetRevenueStats
- Admin-only guards via @Roles('ADMIN') on all endpoints
- Prisma-based admin query repository for dashboard aggregations
- 14 unit tests covering all command handlers and query handlers
- Added activate() method to UserEntity for unban support

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
Ho Ngoc Hai
2026-04-08 02:17:09 +07:00
parent ac3947b42d
commit dafed32e11
49 changed files with 1485 additions and 0 deletions

View File

@@ -85,4 +85,9 @@ export class UserEntity extends AggregateRoot<string> {
this._isActive = false;
this.updatedAt = new Date();
}
activate(): void {
this._isActive = true;
this.updatedAt = new Date();
}
}