aboutsummaryrefslogtreecommitdiffstats
path: root/bin/send-reports
diff options
context:
space:
mode:
Diffstat (limited to 'bin/send-reports')
-rwxr-xr-xbin/send-reports6
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/send-reports b/bin/send-reports
index 8e2f2bd9b..abaf8e77b 100755
--- a/bin/send-reports
+++ b/bin/send-reports
@@ -6,7 +6,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: send-reports,v 1.23 2007-03-21 16:23:58 matthew Exp $
+# $Id: send-reports,v 1.24 2007-03-21 16:34:46 matthew Exp $
use strict;
require 5.8.0;
@@ -78,8 +78,10 @@ foreach my $row (@$unsent) {
push @recips, mySociety::Config::get('CONTACT_EMAIL');
my $template = File::Slurp::read_file("$FindBin::Bin/../templates/emails/submit-council");
- my %h = map { $_ => $row->{$_} } qw/title detail name email phone/;
+ my %h = map { $_ => $row->{$_} } qw/title detail name email phone category/;
$h{phone} = "Phone: $h{phone}\n\n" if $h{phone};
+ $h{category} = ($h{category} eq 'Other' ? '' : "Category: $h{category}\n\n");
+ $h{category_footer} = ($h{category} ? $h{category} : 'local problems');
$h{url} = mySociety::Config::get('BASE_URL') . '/?id=' . $row->{id};
$h{councils_name} = join(' and ', @dear);
$h{fuzzy} = $row->{used_map} ? 'To view a map of the precise location of this issue'