[Rt-commit] r4842 - in rtir/branches/1.9-EXPERIMENTAL: html/RTIR
ruz at bestpractical.com
ruz at bestpractical.com
Sun Mar 26 20:20:36 EST 2006
Author: ruz
Date: Sun Mar 26 20:20:35 2006
New Revision: 4842
Modified:
rtir/branches/1.9-EXPERIMENTAL/ (props changed)
rtir/branches/1.9-EXPERIMENTAL/html/RTIR/Create.html
Log:
r1039 at cubic-pc: cubic | 2006-03-27 05:24:08 +0400
* drop linking to the source ticket while linking with 'MemberOf'
link type with next comment:
# XXX: How do we want to link to the former ticket while split?
# MemberOf is buggy, for example IR(that was not linked to Inc) while split
# generate new IR, but linked to itself, this hides the IR from RTIR at glance.
# also we couldn't see "IR MeberOf IR" links.
# $parentvalue = $TicketObj->Id; # this string was commented out
Modified: rtir/branches/1.9-EXPERIMENTAL/html/RTIR/Create.html
==============================================================================
--- rtir/branches/1.9-EXPERIMENTAL/html/RTIR/Create.html (original)
+++ rtir/branches/1.9-EXPERIMENTAL/html/RTIR/Create.html Sun Mar 26 20:20:35 2006
@@ -66,18 +66,27 @@
% if ( $Split ) {
<input type="hidden" name="Ticket" value="<% $ARGS{'TicketObj'}->Id %>" />
% }
-% my $parentvalue;
-% if ($IncidentObj) {
-% $parentvalue = $IncidentObj->Id;
-% } elsif ($TicketObj) {
-% $parentvalue = $TicketObj->Id;
-% my $incidents = new RT::Tickets( $session{'CurrentUser'} );
-% $incidents->FromSQL( "Queue = 'Incidents' AND HasMember = " . $TicketObj->Id );
-% while (my $incident = $incidents->Next) {
-% $parentvalue .= " ". $incident->Id;
-% }
-% }
-% if (defined $parentvalue) {
+<%PERL>
+my $parentvalue = '';
+if ( $IncidentObj ) {
+ $parentvalue = $IncidentObj->Id;
+} elsif ($TicketObj) {
+
+ # XXX: How do we want to link to the former ticket while split?
+ # MemberOf is buggy, for example IR(that was not linked to Inc) while split
+ # generate new IR, but linked to itself, this hides the IR from RTIR at glance.
+ # also we couldn't see "IR MeberOf IR" links.
+ # $parentvalue = $TicketObj->Id; # this string was commented out
+
+ my $incidents = new RT::Tickets( $session{'CurrentUser'} );
+ $incidents->FromSQL( "Queue = 'Incidents' AND HasMember = " . $TicketObj->Id );
+ while ( my $incident = $incidents->Next ) {
+ $parentvalue .= ' ' if $parentvalue;
+ $parentvalue .= $incident->Id;
+ }
+}
+</%PERL>
+% if ( $parentvalue ) {
<input type="hidden" name="new-MemberOf" value="<% $parentvalue %>" />
% }
More information about the Rt-commit
mailing list