[rt-users] Change the "Modify Ticket" options on blue bar
Stephen Turner
sturner at MIT.EDU
Wed May 28 09:45:01 EDT 2008
At 04:04 PM 5/27/2008, you wrote:
>Stephen,
>
>
> Thanks for the code example. I used it as the basis for the
> code I wanted to add. The "Tabs" layout now shows what I want, but
> when I click any of the new options, nothing happens. This is what
> my new code looks like:
>
>if ($args) {
> $tabs->{"i"} = { path => "Search/Results.html$args",
> title => loc('Show Results'),
> };
> if ($current_tab =~ "Search/Results.html") {
> $current_tab = "Search/Results.html$args";
> };
>}
>
>if ( $can{'ModifyTicket'} ) {
> if ( $Ticket->Status ne 'resolved' ) {
> $actions->{'G'} = {
> path =>
> "Ticket/Update.html?Action=Comment&DefaultStatus=resolved&id=" . $id,
> title => loc('Resolve') };
> }
>
># the following code was added for LBNL
># make sure the check for status is in descending order
>
> if ($Ticket->Status eq 'pending qa')
> {
> $actions->{'Fg'} =
> { path =>
> "Ticket/Display.html?Action=DefaultStatus=('qa approvd')&id=" . $id,
> title => loc('Approve QA'),
> };
> }
Hi Ken,
Just from a quick look at the code, it looks like you're on the right
track. I don't think you need the parentheses or quotes around the
status values - something like:
path => "Ticket/Display.html?Action=DefaultStatus=qa approvd&id=" . $id
As this is going to form a URL, you may need to escape those spaces,
but I'm not sure:
path => "Ticket/Display.html?Action=DefaultStatus=qa%20approvd&id=" . $id
You'll have to play with the options and see if they work. I'm ccing
the list in case someone else has an idea about this.
Good luck,
Steve
More information about the rt-users
mailing list