analytics: customers totals, open counts, normalize education/marriage
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
29867561d1
commit
965b00dba5
2 files changed
+31
-7
No files matched your search
@@ -141,18 +141,23 @@ type ProductsDTO struct {
|
||||
// ---- /customers ----
|
||||
|
||||
// ApprovalCountDTO is a CountDTO plus how many of those loan orders were
|
||||
// approved / rejected, so the UI can show approval rate per group.
|
||||
// approved / rejected / still open, so the UI can show approval rate per group.
|
||||
type ApprovalCountDTO struct {
|
||||
Key string `json:"key"`
|
||||
Count int64 `json:"count"`
|
||||
Percent float64 `json:"percent"`
|
||||
Approved int64 `json:"approved"`
|
||||
Rejected int64 `json:"rejected"`
|
||||
Open int64 `json:"open"`
|
||||
ApprovalRate *float64 `json:"approvalRate"`
|
||||
}
|
||||
|
||||
type CustomersDTO struct {
|
||||
Total int64 `json:"total"`
|
||||
Approved int64 `json:"approved"`
|
||||
Rejected int64 `json:"rejected"`
|
||||
Open int64 `json:"open"`
|
||||
ApprovalRate *float64 `json:"approvalRate"`
|
||||
AgeGroups []ApprovalCountDTO `json:"ageGroups"`
|
||||
Education []ApprovalCountDTO `json:"education"`
|
||||
MarriageStatus []ApprovalCountDTO `json:"marriageStatus"`
|
||||
|
||||
Reference in new issue
Block a user