From c5de0e84387943901e89f8d327d4e97048e7c20c Mon Sep 17 00:00:00 2001 From: Struan Donald Date: Mon, 29 Aug 2011 16:38:23 +0100 Subject: Add address information to description in RSS feeds --- perllib/FixMyStreet/App/Controller/Rss.pm | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'perllib/FixMyStreet/App/Controller/Rss.pm') diff --git a/perllib/FixMyStreet/App/Controller/Rss.pm b/perllib/FixMyStreet/App/Controller/Rss.pm index 45a16a9dd..3a7ffa19a 100755 --- a/perllib/FixMyStreet/App/Controller/Rss.pm +++ b/perllib/FixMyStreet/App/Controller/Rss.pm @@ -263,6 +263,12 @@ sub add_row : Private { my $key = $alert_type->item_table eq 'comment' ? 'c' : 'id'; $item{description} .= ent("\n
cobrand->base_url . "/photo?$key=$row->{id}\">"); } + + if ( $row->{used_map} ) { + my $address = $c->cobrand->find_closest_address_for_rss( $row->{latitude}, $row->{longitude} ); + $item{description} .= ent("\n
$address"); + } + my $recipient_name = $c->cobrand->contact_name; $item{description} .= ent("\n
" . sprintf(_("Report on %s"), $recipient_name) . ""); -- cgit v1.2.3