On Tue, Nov 26, 2013 at 01:58:47PM +0100, Arkadiusz Miśkiewicz wrote:
> Was there any reason for not adding BeforeModify callback in Modify.html? 
> It's 
> logical to have the same sets of callbacks for similar actions IMO.
> 
> This patch below works (hand made, line wrapped, so likely won't apply 
> directly). Please add such modification to 4.2.2. Thanks.

Your patch adds a callback right before another callback which passes
more useful information and can be used to accomplish the same goals.
The existing callback is even visible in your patch.

What does your new callback do that the Default callback doesn't?

-kevin

> --- html/Ticket/Modify.html~   2013-11-25 10:25:50.000000000 +0100
> +++ html/Ticket/Modify.html    2013-11-26 13:36:25.847864830 +0100
> @@ -77,6 +77,9 @@
>  my @results;
>  my $skip_update = 0;
>  
> +$m->callback( CallbackName => 'BeforeModify', ARGSRef => \%ARGS, skip_update 
> => \$skip_update,
> +              results => \@results, TicketObj => $TicketObj );
> +
>  # Now let callbacks have a chance at editing %ARGS
>  $m->callback( TicketObj => $TicketObj, CustomFields => $CustomFields, 
> ARGSRef 
> => \%ARGS, skip_update => \$skip_update );

Attachment: pgpSZSYbfN0e0.pgp
Description: PGP signature

Reply via email to