File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -130,6 +130,9 @@ export default async function DashboardPage({
130130 getDashboardEligibilityLedger ( ) ,
131131 ] )
132132 const eligibilityYears = aggregateEligibilityByYear ( eligibilityLedger , thisYear )
133+ // Total Donations tile = lifetime donations paid out + lifetime bad debts
134+ // written off (both consume donation eligibility).
135+ const totalDonations = eligibilitySummary . totalDonated + eligibilitySummary . totalBadDebt
133136
134137 // Monthly stacked bar dataset for the selected year:
135138 // • carryIn = lifetime cumulative EARNED eligibility BEFORE this month
@@ -194,7 +197,7 @@ export default async function DashboardPage({
194197 return (
195198 < div className = "space-y-8" >
196199 < h1 className = "text-lg font-semibold text-gray-900" > Dashboard</ h1 >
197- < section className = "grid grid-cols-2 gap-4 lg:grid-cols-5 " >
200+ < section className = "grid grid-cols-2 gap-4 lg:grid-cols-3 xl:grid-cols-6 " >
198201 < KpiTile
199202 label = "Total contributions"
200203 value = { formatRupees ( overall . contributions ) }
@@ -229,6 +232,12 @@ export default async function DashboardPage({
229232 hint = "Bank balance + outstanding loan principal"
230233 accent = "amber"
231234 />
235+ < KpiTile
236+ label = "Total donations"
237+ value = { formatRupees ( totalDonations ) }
238+ hint = "Donations paid out + bad debts written off"
239+ accent = "rose"
240+ />
232241 </ section >
233242
234243 < DashboardTabs
You can’t perform that action at this time.
0 commit comments