diff options
author | mark <mark> | 2011-08-23 21:45:51 +0000 |
---|---|---|
committer | mark <mark> | 2011-08-23 21:45:51 +0000 |
commit | 4c8c18409f82d56320a80f6c94f275fa15486897 (patch) | |
tree | deeb2cb64572fb1cd00cb55be48eaa68a69d9984 /rt/lib/RT/Action/SetWillResolve.pm | |
parent | 006b2392be94f9670eddf3d01ba89c00f9c16c05 (diff) |
RT future ticket resolve, #13853
Diffstat (limited to 'rt/lib/RT/Action/SetWillResolve.pm')
-rw-r--r-- | rt/lib/RT/Action/SetWillResolve.pm | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/rt/lib/RT/Action/SetWillResolve.pm b/rt/lib/RT/Action/SetWillResolve.pm new file mode 100644 index 000000000..807b3c64c --- /dev/null +++ b/rt/lib/RT/Action/SetWillResolve.pm @@ -0,0 +1,27 @@ +package RT::Action::SetWillResolve; +use base 'RT::Action'; + +use strict; + +sub Describe { + my $self = shift; + return (ref $self ." will set a ticket's future resolve date to the argument."); +} + +sub Prepare { + return 1; +} + +sub Commit { + my $self = shift; + my $DateObj = RT::Date->new( $self->CurrentUser ); + $DateObj->Set( + Format => 'unknown', + Value => $self->Argument, + ); + $self->TicketObj->SetWillResolve( $DateObj->ISO ); +} + +RT::Base->_ImportOverlays(); + +1; |