aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmktreasurer14
-rw-r--r--tmpl/donations.rss4
-rw-r--r--tmpl/donations_by_month.html2
-rw-r--r--tmpl/donations_by_pa.html2
4 files changed, 11 insertions, 11 deletions
diff --git a/mktreasurer b/mktreasurer
index f46cc0c..5979c6d 100755
--- a/mktreasurer
+++ b/mktreasurer
@@ -47,12 +47,12 @@ sub transactions_list {
: @{$r->{Transaction}};
foreach my $tra (@transactions) {
my %d = (
- nb => $tra->{Nb},
- amount => $tra->{Am},
- date => epoch_date($tra->{Dt}),
- pa => $tra->{Pa},
- who => party_name($r, $tra->{Pa}),
- type => subcat_name($r, $tra->{Sca}, $tra->{Ca}),
+ nb => $tra->{Nb},
+ amount => $tra->{Am},
+ date => epoch_date($tra->{Dt}),
+ pa => $tra->{Pa},
+ who => party_name($r, $tra->{Pa}),
+ sc_name => subcat_name($r, $tra->{Sca}, $tra->{Ca}),
$tra->{No} ne '(null)' ? (notes => $tra->{No}) : (),
);
push @res, \%d;
@@ -87,7 +87,7 @@ sub donations_infos {
(values %{$res{by_pa}})) {
foreach my $don (@{$d->{donations}}) {
$d->{total} += $don->{amount};
- $d->{type}->{$don->{type}} += $don->{amount};
+ $d->{type}->{$don->{sc_name}} += $don->{amount};
}
}
return \%res;
diff --git a/tmpl/donations.rss b/tmpl/donations.rss
index 83bf083..f1c49b0 100644
--- a/tmpl/donations.rss
+++ b/tmpl/donations.rss
@@ -17,9 +17,9 @@
<guid isPermaLink="false">[% config.sitename %]:donations:[% don.nb %]</guid>
[%- USE date %]
<pubDate>[% date.format(don.date, format => '%a, %d %b %Y %H:%M:%S', gmt => 1) %] GMT</pubDate>
- <category>[% don.type %]</category>
+ <category>[% don.sc_name %]</category>
<description>
- [% don.who %] donated [% don.amount %] Euros ([% don.type %]).
+ [% don.who %] donated [% don.amount %] Euros ([% don.sc_name %]).
</description>
</item>
diff --git a/tmpl/donations_by_month.html b/tmpl/donations_by_month.html
index ed4af7f..f539d18 100644
--- a/tmpl/donations_by_month.html
+++ b/tmpl/donations_by_month.html
@@ -20,7 +20,7 @@
<ul>
[%- USE date(format='%Y/%m/%d') -%]
[% FOR don IN donations.by_month.$month.donations %]
- <li><b><a href="donations_p_[% don.pa %].html">[% don.who %]</a></b> donated <b>[% don.amount %]</b> Euros on [% date.format(don.date) %] ([% don.type %])</li>
+ <li><b><a href="donations_p_[% don.pa %].html">[% don.who %]</a></b> donated <b>[% don.amount %]</b> Euros on [% date.format(don.date) %] ([% don.sc_name %])</li>
[%- END -%]
</ul>
</body>
diff --git a/tmpl/donations_by_pa.html b/tmpl/donations_by_pa.html
index 585250e..befbc1e 100644
--- a/tmpl/donations_by_pa.html
+++ b/tmpl/donations_by_pa.html
@@ -20,7 +20,7 @@
<ul>
[%- USE date(format='%Y/%m/%d') -%]
[% FOR don IN donations.by_pa.$pa.donations %]
- <li><b>[% don.amount %]</b> Euros on [% date.format(don.date) %] ([% don.type %])</li>
+ <li><b>[% don.amount %]</b> Euros on [% date.format(don.date) %] ([% don.sc_name %])</li>
[%- END -%]
</ul>
</body>