diff options
author | Struan Donald <struan@exo.org.uk> | 2012-02-27 11:52:54 +0000 |
---|---|---|
committer | Struan Donald <struan@exo.org.uk> | 2012-02-27 11:52:54 +0000 |
commit | 212ea3e9f788c2a83369b02b53c175c1afd8fe0e (patch) | |
tree | 059194a051426ea4680fa477fb6eab48e0823c1f /perllib/FixMyStreet/Cobrand/FixMyStreet.pm | |
parent | 73b9d630c713ca37f86cdff6fa95b64c36f29a31 (diff) |
rough first draft of send-report refactor not. Work in progress at the moment
Diffstat (limited to 'perllib/FixMyStreet/Cobrand/FixMyStreet.pm')
-rw-r--r-- | perllib/FixMyStreet/Cobrand/FixMyStreet.pm | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/FixMyStreet.pm b/perllib/FixMyStreet/Cobrand/FixMyStreet.pm index 37fa7a16d..9958e6215 100644 --- a/perllib/FixMyStreet/Cobrand/FixMyStreet.pm +++ b/perllib/FixMyStreet/Cobrand/FixMyStreet.pm @@ -6,5 +6,18 @@ sub restriction { return {}; } +sub get_council_sender { + my ( $self, $area_id, $area_info ) = shift; + + my $sender_conf = mySociety::Config::get( 'SENDERS' ); + return $sender_conf->{ $council } if exists $sender_conf->{ $council }; + + return 'London' if $area_info->{type} eq 'LBO'; + + return 'Open311' if FixMyStreet::App->model("DB::Open311conf")->search( { area_id => $council, endpoint => { '!=', '' } } )->first; + + return 'Email'; +} + 1; |