[freeside-commits] branch master updated. 42447f6eacba455dcd54403e69f96e78dbe6f01b
Mark Wells
mark at 420.am
Wed Jul 31 14:22:13 PDT 2013
The branch, master has been updated
via 42447f6eacba455dcd54403e69f96e78dbe6f01b (commit)
from af12e29224dd69ef1d577c5e9943644feafe5525 (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 42447f6eacba455dcd54403e69f96e78dbe6f01b
Author: Mark Wells <mark at freeside.biz>
Date: Wed Jul 31 14:17:46 2013 -0700
add RT WillResolve date to ticket search and Edit Basics, #23309
diff --git a/rt/share/html/Elements/RT__Ticket/ColumnMap b/rt/share/html/Elements/RT__Ticket/ColumnMap
index 202a11a..dd1fd39 100644
--- a/rt/share/html/Elements/RT__Ticket/ColumnMap
+++ b/rt/share/html/Elements/RT__Ticket/ColumnMap
@@ -212,6 +212,11 @@ $COLUMN_MAP = {
}
}
},
+ WillResolveRelative => {
+ title => 'Will Resolve',
+ attribute => 'WillResolve',
+ value => sub { return $_[0]->WillResolveObj->AgeAsString },
+ },
ResolvedRelative => {
title => 'Resolved', # loc
attribute => 'Resolved',
@@ -237,6 +242,11 @@ $COLUMN_MAP = {
attribute => 'Due',
value => sub { return $_[0]->DueObj },
},
+ WillResolve => {
+ title => 'Will Resolve',
+ attribute => 'WillResolve',
+ value => sub { return $_[0]->WillResolveObj },
+ },
Resolved => {
title => 'Resolved', # loc
attribute => 'Resolved',
diff --git a/rt/share/html/Elements/SelectDateType b/rt/share/html/Elements/SelectDateType
index 59a7b15..92ae2fc 100755
--- a/rt/share/html/Elements/SelectDateType
+++ b/rt/share/html/Elements/SelectDateType
@@ -53,6 +53,7 @@
<option value="LastUpdated"><&|/l&>Last Updated</&></option>
<option value="Starts"><&|/l&>Starts</&></option>
<option value="Due"><&|/l&>Due</&></option>
+<option value="WillResolve"><&|/l&>Will Resolve</&></option>
<option value="Updated"><&|/l&>Updated</&></option>
</select>
<%ARGS>
diff --git a/rt/share/html/Search/Elements/BuildFormatString b/rt/share/html/Search/Elements/BuildFormatString
index 7224793..6bc12f4 100644
--- a/rt/share/html/Search/Elements/BuildFormatString
+++ b/rt/share/html/Search/Elements/BuildFormatString
@@ -94,6 +94,7 @@ my @fields = (
LastUpdated LastUpdatedRelative
Told ToldRelative
Due DueRelative
+ WillResolve WillResolveRelative
Resolved ResolvedRelative
RefersTo ReferredToBy
diff --git a/rt/share/html/Ticket/Elements/EditBasics b/rt/share/html/Ticket/Elements/EditBasics
index 0d4159f..ae70bd8 100755
--- a/rt/share/html/Ticket/Elements/EditBasics
+++ b/rt/share/html/Ticket/Elements/EditBasics
@@ -65,6 +65,16 @@ unless ( @fields ) {
Default => $defaults{'Status'} || undef,
TicketObj => $TicketObj,
QueueObj => $TicketObj->QueueObj,
+ onchange => 'changeStatus()',
+ },
+ },
+ { name => 'Resolve this Ticket on',
+ comp => '/Elements/SelectDate',
+ args => {
+ menu_prefix => 'WillResolve',
+ Default => $ARGS{'WillResolve'} || $TicketObj->WillResolveObj->Date,
+ current => 0,
+ ShowTime => 0,
},
},
{ name => 'Queue',
@@ -141,4 +151,19 @@ for my $field (@fields) {
% unless ($InTable) {
</table>
% }
-
+<script type="text/javascript">
+function changeStatus() {
+ var Status_select = document.getElementById('Status');
+ var x = Status_select.options[Status_select.selectedIndex].value;
+ var text = document.getElementById('WillResolve_Date');
+ var button = document.getElementById('WillResolve_Date_date_button');
+ if (x == 'resolved' || x == 'rejected' || x == 'deleted') {
+ text.disabled = true;
+ button.style.display = 'none';
+ }
+ else {
+ text.disabled = false;
+ button.style.display = 'inline';
+ }
+}
+</script>
diff --git a/rt/share/html/Ticket/Modify.html b/rt/share/html/Ticket/Modify.html
index 146384e..4b24b89 100755
--- a/rt/share/html/Ticket/Modify.html
+++ b/rt/share/html/Ticket/Modify.html
@@ -82,6 +82,8 @@ my @results;
push @results, ProcessTicketBasics(TicketObj => $TicketObj, ARGSRef => \%ARGS);
push @results, ProcessObjectCustomFieldUpdates(Object => $TicketObj, ARGSRef => \%ARGS);
push @results, ProcessTicketStatus(TicketObj => $TicketObj, ARGSRef => \%ARGS);
+# for WillResolve
+push @results, ProcessTicketDates( TicketObj => $TicketObj, ARGSRef => \%ARGS);
$TicketObj->ApplyTransactionBatch;
-----------------------------------------------------------------------
Summary of changes:
rt/share/html/Elements/RT__Ticket/ColumnMap | 10 ++++++++
rt/share/html/Elements/SelectDateType | 1 +
rt/share/html/Search/Elements/BuildFormatString | 1 +
rt/share/html/Ticket/Elements/EditBasics | 27 ++++++++++++++++++++++-
rt/share/html/Ticket/Modify.html | 2 +
5 files changed, 40 insertions(+), 1 deletions(-)
More information about the freeside-commits
mailing list