SEC-14A
✓ Fully Implemented
Platform Reports (/admin/reports), Billing Revenue Reports & Mosque Kariah Member Reports
Complete specification of all implemented Platform-level and Mosque-level reports, detailing report purpose, authorized roles, filters, data sources, generation steps, and export formats.
Step-by-Step Instructions
1. Platform & Content Summary Report (/admin/reports)
- Report Purpose: Monitor registered mosques by state and status, user and announcement counts, published activities by period/category/mosque, JAKIM prayer sync health, and the 50 most recent security audit logs.
- Authorized Roles:
super_admin(full report + audit log table) andportal_admin(content & activity metrics viareports.content.view). - Data Sources:
mosques,states,users,mosque_announcements,mosque_activities,activity_categories,prayer_zones,prayer_sync_logs, andaudit_logs. - How to Generate & Print: Navigate to
/{lang}/admin/reports. Use browser print (`Ctrl+P` / `Cmd+P`) to print or save as PDF.
2. Platform Billing Revenue Summary (/admin/payments)
- Report Purpose: Track settled subscription revenue (`paid_total`), pending manual verifications (`pending_total`), failed payments (`failed_total`), and overdue invoice balances (`overdue_total`).
- Authorized Roles:
super_admin(`payments.manage`). - Data Sources:
subscription_paymentsandsubscription_invoices.
3. Mosque Kariah Member Directory & Area Report (/mosque-admin/kariah-members)
- Report Purpose: Generate residential area headcounts (Locality/Mukim, Kampung, Taman, Street), status breakdowns, 12-month registration trends, and filtered member lists for a single mosque tenant.
- Authorized Roles:
mosque_admin(`mosque.manage` for on-screen report; `kariah.members.export` for CSV export). - Available Filters: Keyword (`q`), Residential Area (`area_id`), Membership Status (`status`), Registration Date range (`from`, `to`), and Sort (`sort`, `dir`).
- Data Sources:
kariah_members,kariah_people,kariah_areas,kariah_households, andkariah_household_membersscoped to `mosque_id`. - How to Export CSV: Apply desired filters on
/{lang}/mosque-admin/kariah-membersand click Export CSV (`?export=csv`).
Verified Screenshots & UI Reference
Input Fields & Options Reference
| Report Name | Route | Authorized Roles | Supported Export / Print |
|---|---|---|---|
| Platform & Content Report | /admin/reports | super_admin, portal_admin | On-Screen Table / Browser Print |
| Billing Revenue Summary | /admin/payments | super_admin (payments.manage) | On-Screen Summary + Invoice/Receipt PDF |
| Kariah Member Directory Report | /mosque-admin/kariah-members | mosque_admin (kariah.members.export) | UTF-8 BOM CSV Download + On-Screen Table |
Expected Results
Authorized administrators can generate, interpret, and export platform, billing, and kariah membership reports.
Important Notes & Data Boundaries: CSV exports include a UTF-8 byte-order mark (`\xEF\xBB\xBF`) so Microsoft Excel opens Malay and Arabic characters cleanly without encoding corruption.
Common Errors & Troubleshooting
Native `.xlsx` binary export is not used; open the downloaded `.csv` file directly in Microsoft Excel, Google Sheets, or LibreOffice Calc.