[Rt-devel] JSGantt fails when there are external deps

sunnavy sunnavy at bestpractical.com
Wed Sep 22 21:49:11 EDT 2010


thanks, applied in repository.

On 10-09-23 10:33, Jeffrey Fearn wrote:
> Hi, not sure if this is the right place, but when there are external
> links on a ticket, trying to generate a gantt chart fails.
> 
> I've attached a patch that simply ignores external links.
> 
> Cheers, Jeff.
> 
> -- 
> Jeff Fearn <jfearn at redhat.com>
> Software Engineer
> Engineering Operations
> Red Hat, Inc
> Freedom ... courage ... Commitment ... ACCOUNTABILITY

> --- bestpractical-rt-extension-jsgantt-96fb60d/lib/RT/Extension/JSGantt.pm	2010-09-23 09:52:38.000000000 +1000
> +++ patched/lib/RT/Extension/JSGantt.pm	2010-09-23 09:54:31.000000000 +1000
> @@ -61,6 +61,8 @@
>  
>          my $parent = 0;
>          if ( $Ticket->MemberOf->Count ) {
> +            # BUGBUG external links go boom
> +            next unless($Ticket->MemberOf->First->TargetObj);
>              $parent = $Ticket->MemberOf->First->TargetObj->id;
>          }
>  
> @@ -132,6 +134,8 @@
>          my @depends;
>          if ( $depends->Count ) {
>              while ( my $d = $depends->Next ) {
> +                # BUGBUG external links go boom
> +                next unless($d->TargetObj);
>                  push @depends, $d->TargetObj->id;
>              }
>          }

> _______________________________________________
> List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel



More information about the rt-devel mailing list