[freeside-commits] branch FREESIDE_3_BRANCH updated. e46d7128ebe14ac21a8ba4ccb18283b35d72e6f7
Mark Wells
mark at 420.am
Wed Aug 7 16:39:49 PDT 2013
The branch, FREESIDE_3_BRANCH has been updated
via e46d7128ebe14ac21a8ba4ccb18283b35d72e6f7 (commit)
from 44e415a1127cbd4b433ad4b0a7c1432dd935e766 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit e46d7128ebe14ac21a8ba4ccb18283b35d72e6f7
Author: Mark Wells <mark at freeside.biz>
Date: Wed Aug 7 16:39:36 2013 -0700
fix WillResolve date editing in ticket basics, #23309
diff --git a/rt/lib/RT/Interface/Web.pm b/rt/lib/RT/Interface/Web.pm
index bdad213..4a6bfda 100644
--- a/rt/lib/RT/Interface/Web.pm
+++ b/rt/lib/RT/Interface/Web.pm
@@ -2983,6 +2983,7 @@ sub ProcessTicketDates {
Starts
Started
Due
+ WillResolve
);
#Run through each field in this list. update the value if apropriate
diff --git a/rt/lib/RT/Interface/Web_Vendor.pm b/rt/lib/RT/Interface/Web_Vendor.pm
index fb2b807..a5f5b88 100644
--- a/rt/lib/RT/Interface/Web_Vendor.pm
+++ b/rt/lib/RT/Interface/Web_Vendor.pm
@@ -254,8 +254,20 @@ sub ProcessTicketBasics {
TimeLeft
Type
Queue
+ WillResolve
);
+ # the UI for editing WillResolve through Ticket Basics should allow
+ # setting it to null
+ my $to_date = delete($ARGSRef->{'WillResolve_Date'});
+ my $DateObj = RT::Date->new($session{'CurrentUser'});
+ if ( $to_date ) {
+ $DateObj->Set(Format => 'unknown', Value => $to_date);
+ } else {
+ $DateObj->Set(Value => 0);
+ }
+ $ARGSRef->{'WillResolve'} = $DateObj->ISO;
+
if ( $ARGSRef->{'Queue'} and ( $ARGSRef->{'Queue'} !~ /^(\d+)$/ ) ) {
my $tempqueue = RT::Queue->new($RT::SystemUser);
$tempqueue->Load( $ARGSRef->{'Queue'} );
diff --git a/rt/share/html/Ticket/Elements/EditBasics b/rt/share/html/Ticket/Elements/EditBasics
index ae70bd8..a86bb6c 100755
--- a/rt/share/html/Ticket/Elements/EditBasics
+++ b/rt/share/html/Ticket/Elements/EditBasics
@@ -52,6 +52,7 @@ $InTable => 0
%defaults => ()
</%ARGS>
<%INIT>
+my $WillResolveObj = $TicketObj->WillResolveObj;
unless ( @fields ) {
@fields = (
{ name => 'Subject',
@@ -72,7 +73,9 @@ unless ( @fields ) {
comp => '/Elements/SelectDate',
args => {
menu_prefix => 'WillResolve',
- Default => $ARGS{'WillResolve'} || $TicketObj->WillResolveObj->Date,
+ Default => $ARGS{'WillResolve'} ||
+ ($WillResolveObj->Unix > 0 ?
+ $WillResolveObj->Date : ''),
current => 0,
ShowTime => 0,
},
-----------------------------------------------------------------------
Summary of changes:
rt/lib/RT/Interface/Web.pm | 1 +
rt/lib/RT/Interface/Web_Vendor.pm | 12 ++++++++++++
rt/share/html/Ticket/Elements/EditBasics | 5 ++++-
3 files changed, 17 insertions(+), 1 deletions(-)
More information about the freeside-commits
mailing list