including purchase into expenses pie
Deploy to Shared Hosting / Shared hosting deploy (push) Failing after 48s
Tests / PHPUnit (push) Successful in 1m27s

This commit is contained in:
root
2026-09-13 02:45:06 -04:00
parent c3a30989b2
commit 951bb32c3a
3 changed files with 18 additions and 1 deletions
@@ -26,6 +26,10 @@ final class FinancialCategorySummaryService
continue;
}
if (strcasecmp($category, 'Purchase') === 0) {
$category = 'Expense';
}
$expenseCategories[$category] = round(($expenseCategories[$category] ?? 0) + $amount, 2);
$totalExpenses += $amount;
}
+1 -1
View File
@@ -404,7 +404,7 @@ $canViewFinancialStats = (bool) ($canViewFinancialStats ?? false);
pie('studentGenderChart', data.gender, [palette.blue,palette.orange], data.totalStudents);
pie('academicResultsChart', data.results, [palette.green,palette.red,palette.slate], data.totalStudents);
pie('topPerformersChart', data.topGender, [palette.blue,palette.orange], data.totalStudents, 'Other students');
pie('topPerformersChart', data.topGender, [palette.blue,palette.orange], data.totalStudents, 'Not classified as top performers');
new Chart(document.getElementById('classSizeChart'), {
type:'bar',