aboutsummaryrefslogtreecommitdiffstats
path: root/mktreasurer
diff options
context:
space:
mode:
authorNicolas Vigier <boklm@mageia.org>2013-06-19 17:50:34 +0000
committerNicolas Vigier <boklm@mageia.org>2013-06-19 17:50:34 +0000
commit6bfd9cc285b5967180420a86b47db5743771563f (patch)
tree90696a68d545f6a1a97da8a1bca8459421e53648 /mktreasurer
parentbc45ce968f8a889ad50b283fa43c4b94cdeac968 (diff)
downloadmgatres-6bfd9cc285b5967180420a86b47db5743771563f.tar
mgatres-6bfd9cc285b5967180420a86b47db5743771563f.tar.gz
mgatres-6bfd9cc285b5967180420a86b47db5743771563f.tar.bz2
mgatres-6bfd9cc285b5967180420a86b47db5743771563f.tar.xz
mgatres-6bfd9cc285b5967180420a86b47db5743771563f.zip
add total donations to index.json
git-svn-id: svn+ssh://svn.mageia.org/svn/soft/mga-treasurer/trunk@8537 5b7c3c08-40e5-403b-9995-ace06908e4af
Diffstat (limited to 'mktreasurer')
-rwxr-xr-xmktreasurer2
1 files changed, 2 insertions, 0 deletions
diff --git a/mktreasurer b/mktreasurer
index fda59ad..000bef1 100755
--- a/mktreasurer
+++ b/mktreasurer
@@ -83,6 +83,7 @@ sub donations_infos {
by_year => {},
by_pa => {},
total_30 => 0,
+ total => 0,
sorted_pa_by_total => [],
);
foreach my $don (@{$res{donations}}) {
@@ -100,6 +101,7 @@ sub donations_infos {
if (time - $don->{date} < '2592000') { # last 30 days
$res{total_30} += $don->{amount};
}
+ $res{total} += $don->{amount};
}
foreach my $d ((values %{$res{by_month}}), (values %{$res{by_year}}),
(values %{$res{by_pa}})) {