diff options
author | Edmund von der Burg <evdb@mysociety.org> | 2011-04-08 14:35:10 +0100 |
---|---|---|
committer | Edmund von der Burg <evdb@mysociety.org> | 2011-04-08 14:35:10 +0100 |
commit | cf984198252ed545d924985ddeadaae506087ea6 (patch) | |
tree | 6a3146e51c342066e49289f82f7e77c27c52fb0f /perllib/Page.pm | |
parent | 546d9b679f4c56163bbc5df2e98310bc516d3313 (diff) | |
parent | 3134f2bed0d1005b130651a2f4c711ad108798a5 (diff) |
Merge branch 'master' of ssh://evdb@git.mysociety.org/data/git/public/fixmystreet
Diffstat (limited to 'perllib/Page.pm')
-rw-r--r-- | perllib/Page.pm | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/perllib/Page.pm b/perllib/Page.pm index 24c52885a..e659c0af5 100644 --- a/perllib/Page.pm +++ b/perllib/Page.pm @@ -578,12 +578,17 @@ sub display_problem_meta_line($$) { $out .= '; ' . _('the map was not used so pin location may be inaccurate') unless ($problem->{used_map}); if ($problem->{council}) { if ($problem->{whensent}) { - $problem->{council} =~ s/\|.*//g; - my @councils = split /,/, $problem->{council}; - my $areas_info = mySociety::MaPit::call('areas', \@councils); - my $council = join(' and ', map { $areas_info->{$_}->{name} } @councils); + my $body; + if ($problem->{external_body}) { + $body = $problem->{external_body}; + } else { + $problem->{council} =~ s/\|.*//g; + my @councils = split /,/, $problem->{council}; + my $areas_info = mySociety::MaPit::call('areas', \@councils); + $body = join(' and ', map { $areas_info->{$_}->{name} } @councils); + } $out .= '<small class="council_sent_info">'; - $out .= $q->br() . sprintf(_('Sent to %s %s later'), $council, prettify_duration($problem->{whensent}, 'minute')); + $out .= $q->br() . sprintf(_('Sent to %s %s later'), $body, prettify_duration($problem->{whensent}, 'minute')); $out .= '</small>'; } } else { |