feat: initialize project backend structure and document system specifications across all modules

This commit is contained in:
SonPhung
2026-07-24 09:05:41 +07:00
parent 506008c69f
commit 4534e4ecb8
74 changed files with 7989 additions and 44 deletions

View File

@@ -0,0 +1,54 @@
---
title: "Pool Balance Detail"
type: OpenSpec
status: Draft
domain: Customer Management
---
# Pool Balance Detail
## Requirement Definition
Provides a summary and detailed breakdown of all reward pools and their balance buckets for a selected customer.
## Process Flow
### Pre-Conditions
- Users must have access rights in the "Balance Enquiry" module.
## Business Rules
### Data Schema
#### Pool Balance Summary
Displays a row for each pool the customer interacts with.
| Field Name | Description | Logic Type | Constraints / Rules |
|---|---|---|---|
| Pool ID | Pool ID. | String | Read-only. |
| Pool Name | Pool Name. | String | Read-only. |
| Pool Type | Pool Type. | String | Read-only. |
| Pool Entity Level | Customer, Account, or Card level. | String | Read-only. |
| Balance | Sum of all balance buckets. | Decimal | Read-only. |
| Redeemable Balance | Sum of non-expired, available buckets. | Decimal | Read-only. |
| Next Expiring Balance | The earliest non-expired balance bucket amount. | Decimal | Read-only. |
#### Pool Balance Detail (Bucket Breakdown)
Displays the individual expiry buckets for a selected pool.
| Field Name | Description | Logic Type | Constraints / Rules |
|---|---|---|---|
| Account Type | Account Type. | String | Read-only. |
| Account No | Account Number. | String | Read-only. |
| Card Number | Card Number (only if Card pool entity level). | String | Read-only. |
| Pool ID | Selected Pool ID. | String | Read-only. |
| Balance | Non-zero balance of the bucket. | Decimal | Read-only. |
| Expiry Date | Expiring date of the bucket. | Date | Read-only. |
### Execution
- **View-only screen.** No modifications allowed directly.
- Grouping/Visibility is dependent on the Pool Entity Level:
- Customer level: Shows buckets grouped under accounts, even though earned at customer level.
- Account level: Shows buckets earned by the specific Account.
- Card level: Shows buckets earned by the specific Card.
- Expired buckets that have not yet forfeited are shown.
## Exception Flow
- N/A