diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2016-08-26 15:05:30 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2016-08-26 15:05:30 +0100 |
commit | 0e45fa27e4bc857f61b71f6c121a61e08e54cb6a (patch) | |
tree | 7e83c50825819b60a9a73f16c4d4f0a4ff247650 /perllib/Open311/Endpoint/Service/Request.pm | |
parent | c1178ea85d1879d6533ac09e2a3c813441554b43 (diff) | |
parent | a09c61c807d8d6b50227c9d8aa687f1eb22bad00 (diff) |
Merge branch 'stevenage-open311'
Diffstat (limited to 'perllib/Open311/Endpoint/Service/Request.pm')
-rw-r--r-- | perllib/Open311/Endpoint/Service/Request.pm | 110 |
1 files changed, 0 insertions, 110 deletions
diff --git a/perllib/Open311/Endpoint/Service/Request.pm b/perllib/Open311/Endpoint/Service/Request.pm deleted file mode 100644 index 8dfa5df3a..000000000 --- a/perllib/Open311/Endpoint/Service/Request.pm +++ /dev/null @@ -1,110 +0,0 @@ -package Open311::Endpoint::Service::Request; -use Moo; -use MooX::HandlesVia; -use Types::Standard ':all'; -use namespace::clean; - -has service => ( - is => 'ro', - isa => InstanceOf['Open311::Endpoint::Service'], - handles => [ - qw/ service_code service_name / - ], -); - -has service_request_id => ( - is => 'ro', - isa => Maybe[Str], - predicate => 1, -); - -has token => ( - is => 'ro', - isa => Maybe[Str], - predicate => 1, -); - -has service_notice => ( - is => 'ro', - isa => Maybe[Str], - predicate => 1, -); - -has account_id => ( - is => 'ro', - isa => Maybe[Str], - predicate => 1, -); - -has status => ( - is => 'rw', - isa => Enum[qw/ open closed /], - default => sub { 'open' }, -); - -has description => ( - is => 'ro', - isa => Maybe[Str], -); - -has agency_responsible => ( - is => 'ro', - isa => Maybe[Str], -); - -has requested_datetime => ( - is => 'ro', - isa => Maybe[ InstanceOf['DateTime'] ], - default => sub { DateTime->now() }, -); - -has updated_datetime => ( - is => 'rw', - isa => Maybe[ InstanceOf['DateTime'] ], - default => sub { DateTime->now() }, -); - -has expected_datetime => ( - is => 'ro', - isa => Maybe[ InstanceOf['DateTime'] ], -); - -has address => ( - is => 'ro', - isa => Str, - default => sub { '' }, -); - -has address_id => ( - is => 'ro', - isa => Str, - default => sub { '' }, -); - -has zipcode => ( - is => 'ro', - isa => Str, - default => sub { '' }, -); - -has latlong => ( - is => 'ro', - isa => Tuple[ Num, Num ], - default => sub { [0,0] }, - handles_via => 'Array', - handles => { - #lat => [ get => 0 ], - #long => [ get => 1 ], - } -); - -sub lat { shift->latlong->[0] } -sub long { shift->latlong->[1] } - -has media_url => ( - is => 'ro', - isa => Str, - default => sub { '' }, -); - -1; |