aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/View
diff options
context:
space:
mode:
authorEdmund von der Burg <evdb@mysociety.org>2011-03-28 14:21:56 +0100
committerEdmund von der Burg <evdb@mysociety.org>2011-03-28 14:21:56 +0100
commit9942c5c59ab28d0441ea5ba49a7bd426f17e45c3 (patch)
tree95449ac8b6e0f7069bdb7aa73c71ad1b1fbdf85d /perllib/FixMyStreet/App/View
parent632dd7b8e84faa4bcb19401678565751677729cc (diff)
Handle problem confirmation tokens in catalyst and get all tests working
Diffstat (limited to 'perllib/FixMyStreet/App/View')
-rw-r--r--perllib/FixMyStreet/App/View/Web.pm15
1 files changed, 15 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/App/View/Web.pm b/perllib/FixMyStreet/App/View/Web.pm
index e5983ea23..75ca4dd81 100644
--- a/perllib/FixMyStreet/App/View/Web.pm
+++ b/perllib/FixMyStreet/App/View/Web.pm
@@ -66,5 +66,20 @@ sub tprintf {
return sprintf $format, @args;
}
+=head2 display_crossell_advert
+
+ [% display_crossell_advert( email, name ) %]
+
+Displays a crosssell advert if permitted by the cobrand.
+
+=cut
+
+sub display_crossell_advert {
+ my ( $self, $c, $email, $name ) = @_;
+
+ return unless $c->cobrand->allow_crosssell_adverts();
+ return CrossSell::display_advert( $c->req, $email, $name );
+}
+
1;