[rt-users] FW: Custom Scrip Help
Carlos A. Alvarez
carlos.alvarez at commxinc.com
Tue Jul 14 12:14:14 EDT 2009
-----Original Message-----
From: Carlos A. Alvarez
Sent: Tuesday, July 14, 2009 12:02 PM
To: 'Ruslan Zakirov'
Subject: RE: Custom Scrip Help
I see that thanks!... But I still can't find a place where a list of Obj are located. For example:
TicketObj
Owner
Status
TransactionObj
CreatorObj
Type
Correspond
Comment
More like a reference guide, you know so we can construct valid statements. Does something like this exists or am I reaching?
Guessing I would have to build a custom scrip condition like :
if ( $self->TransactionObj->Type eq "Correspond" &&
$self->TransactionObj->CreatorObj == TicketObj->Requestor)
{
return 1;
} else {
return undef;
}
So only applies this Scrip when the requestor is replying to a message?
Thanks for the input!
-----Original Message-----
From: Ruslan Zakirov [mailto:ruslan.zakirov at gmail.com]
Sent: Tuesday, July 14, 2009 10:21 AM
To: Carlos A. Alvarez
Cc: rt-users at lists.bestpractical.com
Subject: Re: Custom Scrip Help
Tried the following?
http://wiki.bestpractical.com/view/CustomConditionSnippets
On Tue, Jul 14, 2009 at 6:18 PM, Carlos A.
Alvarez<carlos.alvarez at commxinc.com> wrote:
> Thanks Ruslan,
>
> You mean instead of using the default condition "On Correspond"? Can you point me to a source for TicketObj options and TransactionObj options, so I can create a custom condition. I look everywhere I even bought the RT Essentials book and tried perdocs, and I cant find a list of Class Objects like AddCustomFieldValues, or a list of RT variables.
>
> Carlos
> -----Original Message-----
> From: Ruslan Zakirov [mailto:ruslan.zakirov at gmail.com]
> Sent: Tuesday, July 14, 2009 5:50 AM
> To: Carlos A. Alvarez
> Cc: rt-users at lists.bestpractical.com
> Subject: Re: [rt-users] (no subject)
>
> You need condition as well. Also adding space as value is not a good
> option, use DeleteCustomFieldValue method.
>
> On Tue, Jul 14, 2009 at 5:59 AM, Carlos A.
> Alvarez<carlos.alvarez at commxinc.com> wrote:
>>
>>
>> I will like to create a scrip where the status of a ticket is automatically
>> changed from open to stalled when a Owner replies to a requestor. I am using
>> rt-crontool to monitor the status of the tickets and auto resolve the ticket
>> after 72 hours of inactivity. I created a custom field to monitor the
>> status of the crontool, but my problem is that when the customer replies, I
>> can’t rely on my techs to change the status of the ticket manually.
>>
>>
>>
>> I tried creating User Defined Scrip which works fine, exept it executes each
>> time, indiscriminately. Let me try to explain, I have one script that
>> changes the status from open to stalled, when a technician replies, and
>> another that changed the status back to open when the customer/requestor
>> replies. I can see that both scrips are executing at the same time
>> regardless of who initiated the correspondence.
>>
>>
>>
>> I know that I am missing something basic, but I don’t know what. Can anyone
>> help.
>>
>>
>>
>> Scrip 1 customer reply
>>
>> $self->TicketObj->AddCustomFieldValue(Field => 'Support Status', Value => '
>> ');
>>
>> $self->TicketObj->AddCustomFieldValue(Field => 'AutoClosure', Value => ' ');
>>
>> $self->TicketObj->SetStatus("open");
>>
>> return 1;
>>
>>
>>
>> Scrip 2 Owner reply
>>
>> $self->TicketObj->AddCustomFieldValue(Field => 'Support Status', Value =>
>> 'Awaiting Customer');
>>
>> $self->TicketObj->SetStatus("stalled");
>>
>> return 1;
>>
>>
>>
>> Thanks…
>>
>> _______________________________________________
>> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
>>
>> Community help: http://wiki.bestpractical.com
>> Commercial support: sales at bestpractical.com
>>
>>
>> Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
>> Buy a copy at http://rtbook.bestpractical.com
>>
>
>
>
> --
> Best regards, Ruslan.
>
--
Best regards, Ruslan.
More information about the rt-users
mailing list