[Rt-commit] rtir branch, 2.6-trunk, updated. 2.6.2rc1-1-g8535f78
Ruslan Zakirov
ruz at bestpractical.com
Tue Aug 14 16:12:30 EDT 2012
The branch, 2.6-trunk has been updated
via 8535f782e33e2d5697a9600ddc23b6db127d3231 (commit)
from aa75e5ab0726e73e451394ba9e40d30548676db5 (commit)
Summary of changes:
html/RTIR/Reporting/index.html | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
- Log -----------------------------------------------------------------
commit 8535f782e33e2d5697a9600ddc23b6db127d3231
Author: Kevin Falcone <falcone at bestpractical.com>
Date: Thu Aug 9 18:51:56 2012 -0400
Ensure that reports are passed the Constituency selected on the index.html
Back in 2.4, EditRTIRField would put a Constituency field in as a hidden
field with a pointer to which element in the $ARGS to look up to get the
selected value. Because we stopped doing this in 2.6,
$ARGS{Constituency} doesn't exist and can't be used to pull the selected
value out. The smalled fix appears to be to load the CF and just use it
to get the expected data out of %ARGS.
If you're not using constituencies, I don't think Reports work terribly
well, so some future work is required to hide the empty dropdown and
ensure that limits don't rely on them.
diff --git a/html/RTIR/Reporting/index.html b/html/RTIR/Reporting/index.html
index 89d5055..ae18a1a 100644
--- a/html/RTIR/Reporting/index.html
+++ b/html/RTIR/Reporting/index.html
@@ -75,9 +75,9 @@
<%INIT>
if ( $ARGS{'HTMLReport'} || $ARGS{'TextReport'} || $ARGS{'SpreadsheetReport'} ) {
- if ( $ARGS{'Constituency'} ) {
- delete $ARGS{ 'Object-RT::Ticket--'. $ARGS{'Constituency'} .'-Magic' };
- $ARGS{'Constituency'} = delete $ARGS{ 'Object-RT::Ticket--'. $ARGS{'Constituency'} };
+ unless ( $ARGS{'Constituency'} ) {
+ my $constituency_cf = RT::IR::GetCustomField('Constituency');
+ $ARGS{'Constituency'} = delete $ARGS{ 'Object-RT::Ticket--CustomField-'. $constituency_cf->Id .'-Values' };
}
my $ext = 'html';
$ext = 'txt' if $ARGS{'TextReport'};
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list