I found a list of condition snippets that was great, but for all it had, it
missed any examples related to when a new requestor is added.
One scenario is that technicians frequently take a phone call and create the
ticket for the requestor. That makes them the requestor and then they have
to go in and change it to the correct person.
Another possibility is that they simply need to add a second name as
requestor.
I’m not a Perl person so writing conditions in a scrip for me is really a
matter of finding an existing example and copying it. Does anyone have
snippet to show me how to isolate the Adding of a Requestor?
Thanks,
-Rick
View this message in context: http://requesttracker.8502.n7.nabble.com/How-to-create-a-scrip-Condition-for-OnAddRequestor-tp56325.html
I found a list of condition snippets that was great, but for all it had, it
missed any examples related to when a new requestor is added.
One scenario is that technicians frequently take a phone call and create the
ticket for the requestor. That makes them the requestor and then they have
to go in and change it to the correct person.
you may:
- disable CurrentUser to be the default requestor (empty field)
- use RT::Extension::MendatoryRequestor to force your staff to enter a
valid one
that would reduce the wrong requestors.
you may also tweak your IPBX to create the ticket and lookup the
requestor in a directory (hints: asterisk, RT REST access, LDAP/Customer
database) 
Another possibility is that they simply need to add a second name as
requestor.
Even it’s allowed to use multiple requestors in RT, I personnaly don’t
like this as it may make things complicate when it comes to automate
based on requestor.
But if you wan’t to do so, your staff can:
- do it when creating the ticket, “their email, customer email” in
Requestor field
- do it after ticket creation using the “People” link in the ticket
menu.
Easter-eggs Spécialiste GNU/Linux
44-46 rue de l’Ouest - 75014 Paris - France - Métro Gaité
Phone: +33 (0) 1 43 35 00 37 - Fax: +33 (0) 1 43 35 00 76
mailto:elacour@easter-eggs.com - http://www.easter-eggs.com
Emmanuel,
Thanks for great input but those things we are already doing.
The key, though, is that when a new requester IS added, for any reason,
they need to receive an email (the Autoreply template, actually) letting
them know. That’s what I need the condition for - how to trap the
addition of a new Requester so I can then Notify Requesters in a scrip.
The normal scrip only fires On Create - I need one to fire On Add Requester.
Thanks,
-RickOn 1/17/2014 7:43 AM, Emmanuel Lacour [via RequestTracker] wrote:
On Thu, Jan 16, 2014 at 12:29:12PM -0800, rwzoerner wrote:
I found a list of condition snippets that was great, but for all it
had, it
missed any examples related to when a new requestor is added.
One scenario is that technicians frequently take a phone call and
create the
ticket for the requestor. That makes them the requestor and then
they have
to go in and change it to the correct person.
you may:
- disable CurrentUser to be the default requestor (empty field)
- use RT::Extension::MendatoryRequestor to force your staff to enter a
valid one
that would reduce the wrong requestors.
you may also tweak your IPBX to create the ticket and lookup the
requestor in a directory (hints: asterisk, RT REST access, LDAP/Customer
database) 
Another possibility is that they simply need to add a second name as
requestor.
Even it’s allowed to use multiple requestors in RT, I personnaly don’t
like this as it may make things complicate when it comes to automate
based on requestor.
But if you wan’t to do so, your staff can:
- do it when creating the ticket, “their email, customer email” in
Requestor field
- do it after ticket creation using the “People” link in the ticket
menu.
–
Easter-eggs Spécialiste GNU/Linux
44-46 rue de l’Ouest - 75014 Paris - France - Métro Gaité
Phone: +33 (0) 1 43 35 00 37 - Fax: +33 (0) 1 43 35 00 76
mailto:[hidden email] </user/SendEmail.jtp?type=node&node=56338&i=0>
If you reply to this email, your message will be added to the
discussion below:
http://requesttracker.8502.n7.nabble.com/How-to-create-a-scrip-Condition-for-OnAddRequestor-tp56325p56338.html
To unsubscribe from How to create a scrip Condition for
OnAddRequestor, click here
http://requesttracker.8502.n7.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=56325&code=cmlja0B6b2VybmVyLmNvbXw1NjMyNXwtMTczNDEzOTU5OQ==.
NAML
http://requesttracker.8502.n7.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html!nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers!nabble%3Aemail.naml-instant_emails!nabble%3Aemail.naml-send_instant_email!nabble%3Aemail.naml
View this message in context: http://requesttracker.8502.n7.nabble.com/How-to-create-a-scrip-Condition-for-OnAddRequestor-tp56325p56339.html
Emmanuel,
Thanks for great input but those things we are already doing.
The key, though, is that when a new requester IS added, for any reason,
they need to receive an email (the Autoreply template, actually) letting
them know. That’s what I need the condition for - how to trap the addition
of a new Requester so I can then Notify Requesters in a scrip. The normal
scrip only fires On Create - I need one to fire On Add Requester.
For your UserDefined condition, adding a Requestor is matched via:
if ( $self->TransactionObj->Type eq ‘AddWatcher’ &&
$self->TransactionObj->Field eq ‘Requestor’ ) {
…
you may check also that we are adding a requestor and not changing an
existing one:
if ( ! $self->TransactionObj->OldValue ) {
The new requestor id will be in $self->TransactionObj->NewValue, you have to load it as a RT::User to get the EmailAddress and use it in your template.
Easter-eggs Spécialiste GNU/Linux
44-46 rue de l’Ouest - 75014 Paris - France - Métro Gaité
Phone: +33 (0) 1 43 35 00 37 - Fax: +33 (0) 1 43 35 00 76
mailto:elacour@easter-eggs.com - http://www.easter-eggs.com
Thanks! I think that is exactly what I needed.
-RickOn 1/17/2014 9:52 AM, Emmanuel Lacour [via RequestTracker] wrote:
On Fri, Jan 17, 2014 at 07:10:43AM -0800, rwzoerner wrote:
Emmanuel,
Thanks for great input but those things we are already doing.
The key, though, is that when a new requester IS added, for any
reason,
they need to receive an email (the Autoreply template, actually)
letting
them know. That’s what I need the condition for - how to trap the
addition
of a new Requester so I can then Notify Requesters in a scrip.
The normal
scrip only fires On Create - I need one to fire On Add Requester.
For your UserDefined condition, adding a Requestor is matched via:
if ( $self->TransactionObj->Type eq ‘AddWatcher’ &&
$self->TransactionObj->Field eq ‘Requestor’ ) {
…
you may check also that we are adding a requestor and not changing an
existing one:
if ( ! $self->TransactionObj->OldValue ) {
The new requestor id will be in $self->TransactionObj->NewValue, you
have to load it as a RT::User to get the EmailAddress and use it in
your template.
–
Easter-eggs Spécialiste GNU/Linux
44-46 rue de l’Ouest - 75014 Paris - France - Métro Gaité
Phone: +33 (0) 1 43 35 00 37 - Fax: +33 (0) 1 43 35 00 76
mailto:[hidden email] </user/SendEmail.jtp?type=node&node=56341&i=0>
If you reply to this email, your message will be added to the
discussion below:
http://requesttracker.8502.n7.nabble.com/How-to-create-a-scrip-Condition-for-OnAddRequestor-tp56325p56341.html
To unsubscribe from How to create a scrip Condition for
OnAddRequestor, click here
http://requesttracker.8502.n7.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=56325&code=cmlja0B6b2VybmVyLmNvbXw1NjMyNXwtMTczNDEzOTU5OQ==.
NAML
http://requesttracker.8502.n7.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html!nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers!nabble%3Aemail.naml-instant_emails!nabble%3Aemail.naml-send_instant_email!nabble%3Aemail.naml
View this message in context: http://requesttracker.8502.n7.nabble.com/How-to-create-a-scrip-Condition-for-OnAddRequestor-tp56325p56347.html