[rt-users] Trying to modify the Quick Ticket function
Kenneth Marshall
ktm at rice.edu
Thu Feb 3 14:45:46 EST 2011
On Thu, Feb 03, 2011 at 12:38:41PM -0600, Chris Barnes wrote:
> On the dashboard (is that it - the "home"?) there is this neat thing called
> "Quick Ticket Creation".
>
> Because of the way we do things, this area is really only useful to us to
> "log quickie, one time events". That is,
> * if one of the IT folks need to create a ticket with some actual content,
> we use the "new ticket in" button at the top.
> * users create tickets by sending us email (ie. they do NOT have accounts
> in RT).
>
>
> Thus, since we want to use the Quick Ticket area for "event logging", there
> are a couple of things we are trying to accomplish by modifying it's
> function
>
> (1) the ticket needs to have the status set to "Resolved"
>
> (2) it does NOT send email to the requestor (at all, ever).
> note that we DO want to send email to the requestor from other functions,
> so we do NOT want to blow away the ability to send email when we set a
> "normal" ticket to resolved.
>
>
>
> I am trying to make this change in RT by modifying the Mason script.
> /opt/rt3/share/html/Ticket/ModifyAll.html has the following section
>
> <tr>
> <td class="label"><&|/l&>Update Type</&>:</td>
> <td class="entry">
> <select name="UpdateType">
> % if ($CanComment) {
> <option value="private" ><&|/l&>Comments (Not sent to
> requestors)</&></option>
> % }
> % if ($CanRespond) {
> <option value="response"><&|/l&>Reply to requestors</&></option>
> % }
> </select>
> % $m->callback( %ARGS, CallbackName => 'AfterUpdateType' );
> </td>
> </tr>
>
> I simply tried to splice this
> into /opt/rt3/share/html/Elements/QuickCreate
>
> <tr class="input-row">
> <td class="labeltop"><&|/l&>Content</&>:</td>
> <td colspan="3" class="value"><textarea name="Content" cols="50"
> rows="3"></textarea></td></tr>
>
> <tr>
> <td class="label"><&|/l&>Update Type</&>:</td>
> <td class="entry">
> <select name="UpdateType">
> % if ($CanComment) {
> <option value="private" ><&|/l&>Comments (Not sent to
> requestors)</&></option>
> % }
> % if ($CanRespond) {
> <option value="response"><&|/l&>Reply to requestors</&></option>
> % }
> </select>
> % $m->callback( %ARGS, CallbackName => 'AfterUpdateType' );
> </td>
> </tr>
>
> </table>
> <& /Elements/Submit, Label => loc('Create') &>
> </form>
> </&>
>
> % $m->callback( CallbackName => 'EndOfList', TicketObj => $TicketObj, %
> ARGS );
> </div>
>
> <%INIT>
>
> my $CanRespond = 1;
> my $CanComment = 1;
> my $checks_failure = 0;
> my $title;
>
> # Things needed in the template - we'll do the processing here, just
> # for the convenience:
>
> my ($CommentDefault, $ResponseDefault);
> $CommentDefault = qq[ selected="selected"];
> $ResponseDefault = qq[ selected="selected"];
>
> </%INIT>
>
> <%ARGS>
>
> $TicketObj => undef
>
>
>
>
>
> Problem #1 is that this generates two tickets
>
> Problem #2 is that it is sending a reply to the requestor (actually 2
> replies, but that is probably due to Problem #1).
>
>
> Is this even the right way to go about trying to implement his feature
> change? Or am I barking up the wrong tree?
>
> --
> Chris Barnes AOL IM: CNBarnes
> chris-barnes at tamu.edu Yahoo IM: chrisnbarnes
> Computer Systems Manager MSN IM: chris at txbarnes.com
> Department of Physics ph: 979-845-1379
> Texas A&M University fax: 979-845-2590
>
Hi Chris,
I can think of several ways to do this. If you only need this function
for a several queues, make a shadow queue for each queue called qt:queue
to place them near each other. Then configure the scrips for your shadow
queue to assign/process the queue as describe. Another way is to have
creation using the quick ticket method set a global custom field and use
that to trigger your alternate processing.
Cheers,
Ken
More information about the rt-users
mailing list