1 # Initial data for a fresh RT installation.
6 RealName => 'Enoch Root',
7 Password => 'password',
8 EmailAddress => "root\@localhost",
9 Comments => 'SuperUser',
17 @Queues = ({ Name => 'General',
18 Description => 'The default queue',
19 CorrespondAddress => "",
20 CommentAddress => "", },
21 { Name => '___Approvals',
22 Lifecycle => 'approvals',
23 Description => 'A system-internal queue for the approvals system',
28 { Name => 'Autoreply To Requestors', # loc
30 'Always sends a message to the requestors independent of message sender' , # loc
31 ExecModule => 'Autoreply',
32 Argument => 'Requestor' },
33 { Name => 'Notify Requestors', # loc
34 Description => 'Sends a message to the requestors', # loc
35 ExecModule => 'Notify',
36 Argument => 'Requestor' },
37 { Name => 'Notify Owner as Comment', # loc
38 Description => 'Sends mail to the owner', # loc
39 ExecModule => 'NotifyAsComment',
40 Argument => 'Owner' },
41 { Name => 'Notify Owner', # loc
42 Description => 'Sends mail to the owner', # loc
43 ExecModule => 'Notify',
44 Argument => 'Owner' },
45 { Name => 'Notify Ccs as Comment', # loc
46 Description => 'Sends mail to the Ccs as a comment', # loc
47 ExecModule => 'NotifyAsComment',
49 { Name => 'Notify Ccs', # loc
50 Description => 'Sends mail to the Ccs', # loc
51 ExecModule => 'Notify',
53 { Name => 'Notify AdminCcs as Comment', # loc
54 Description => 'Sends mail to the administrative Ccs as a comment', # loc
55 ExecModule => 'NotifyAsComment',
56 Argument => 'AdminCc' },
57 { Name => 'Notify AdminCcs', # loc
58 Description => 'Sends mail to the administrative Ccs', # loc
59 ExecModule => 'Notify',
60 Argument => 'AdminCc' },
61 { Name => 'Notify Owner and AdminCcs', # loc
62 Description => 'Sends mail to the Owner and administrative Ccs', # loc
63 ExecModule => 'Notify',
64 Argument => 'Owner,AdminCc' },
65 { Name => 'Notify Owner or AdminCcs', # loc
66 Description => 'Sends mail to the Owner if set, otherwise administrative Ccs', # loc
67 ExecModule => 'NotifyOwnerOrAdminCc',
69 { Name => 'Notify Requestors and Ccs as Comment', # loc
70 Description => 'Send mail to requestors and Ccs as a comment', # loc
71 ExecModule => 'NotifyAsComment',
72 Argument => 'Requestor,Cc' },
75 # { Name => 'Notify Requestors and Ccs', # loc
76 # Description => 'Send mail to requestors and Ccs', # loc
77 # ExecModule => 'Notify',
78 # Argument => 'Requestor,Cc' },
81 { Name => 'Notify Owner, Requestors, Ccs and AdminCcs as Comment', # loc
82 Description => 'Send mail to owner and all watchers as a "comment"', # loc
83 ExecModule => 'NotifyAsComment',
85 { Name => 'Notify Owner, Requestors, Ccs and AdminCcs', # loc
86 Description => 'Send mail to owner and all watchers', # loc
87 ExecModule => 'Notify',
89 { Name => 'Notify Other Recipients as Comment', # loc
90 Description => 'Sends mail to explicitly listed Ccs and Bccs', # loc
91 ExecModule => 'NotifyAsComment',
92 Argument => 'OtherRecipients' },
94 # { Name => 'Notify Other Recipients', # loc
95 # Description => 'Sends mail to explicitly listed Ccs and Bccs', # loc
96 # ExecModule => 'Notify',
97 # Argument => 'OtherRecipients' },
99 { Name => 'User Defined', # loc
100 Description => 'Perform a user-defined action', # loc
101 ExecModule => 'UserDefined', },
102 { Name => 'Create Tickets', # loc
104 'Create new tickets based on this scrip\'s template', # loc
105 ExecModule => 'CreateTickets', },
106 { Name => 'Open Tickets', # loc
107 Description => 'Open tickets on correspondence', # loc
108 ExecModule => 'AutoOpen' },
109 { Name => 'Open Inactive Tickets', # loc
110 Description => 'Open inactive tickets', # loc
111 ExecModule => 'AutoOpenInactive' },
112 { Name => 'Extract Subject Tag', # loc
113 Description => 'Extract tags from a Transaction\'s subject and add them to the Ticket\'s subject.', # loc
114 ExecModule => 'ExtractSubjectTag' },
115 { Name => 'Send Forward', # loc
116 Description => 'Send forwarded message', # loc
117 ExecModule => 'SendForward', },
119 { Name => 'Set Priority',
120 Description => 'Set ticket priority',
121 ExecModule => 'SetPriority',
124 { Name => 'Cancel Scheduled Resolve',
125 Description => 'Set ticket not to resolve in the future',
126 ExecModule => 'SetWillResolve',
129 { Name => 'Scheduled Resolve',
130 Description => 'Resolve ticket if its WillResolve date has passed',
131 ExecModule => 'ScheduledResolve',
134 # combine these into a single action so they can see each other in the headers
135 { Name => 'Notify Requestors, Ccs, and Other Recipients',
136 Description => 'Send mail to requestors, watchers, and explicit Ccs',
137 ExecModule => 'Notify',
138 Argument => 'Requestor,Cc,OtherRecipients',
143 { Name => 'On Create', # loc
144 Description => 'When a ticket is created', # loc
145 ApplicableTransTypes => 'Create',
146 ExecModule => 'AnyTransaction', },
148 { Name => 'On Transaction', # loc
149 Description => 'When anything happens', # loc
150 ApplicableTransTypes => 'Any',
151 ExecModule => 'AnyTransaction', },
154 Name => 'On Correspond', # loc
155 Description => 'Whenever correspondence comes in', # loc
156 ApplicableTransTypes => 'Correspond',
157 ExecModule => 'AnyTransaction', },
161 Name => 'On Forward', # loc
162 Description => 'Whenever a ticket or transaction is forwarded', # loc
163 ApplicableTransTypes => 'Forward Transaction,Forward Ticket',
164 ExecModule => 'AnyTransaction', },
168 Name => 'On Forward Ticket', # loc
169 Description => 'Whenever a ticket is forwarded', # loc
170 ApplicableTransTypes => 'Forward Ticket',
171 ExecModule => 'AnyTransaction', },
175 Name => 'On Forward Transaction', # loc
176 Description => 'Whenever a transaction is forwarded', # loc
177 ApplicableTransTypes => 'Forward Transaction',
178 ExecModule => 'AnyTransaction', },
182 Name => 'On Comment', # loc
183 Description => 'Whenever comments come in', # loc
184 ApplicableTransTypes => 'Comment',
185 ExecModule => 'AnyTransaction' },
188 Name => 'On Status Change', # loc
189 Description => 'Whenever a ticket\'s status changes', # loc
190 ApplicableTransTypes => 'Status',
191 ExecModule => 'AnyTransaction',
196 Name => 'On Priority Change', # loc
197 Description => 'Whenever a ticket\'s priority changes', # loc
198 ApplicableTransTypes => 'Set',
199 ExecModule => 'PriorityChange',
203 Name => 'On Owner Change', # loc
204 Description => 'Whenever a ticket\'s owner changes', # loc
205 ApplicableTransTypes => 'Any',
206 ExecModule => 'OwnerChange',
211 Name => 'On Queue Change', # loc
212 Description => 'Whenever a ticket\'s queue changes', # loc
213 ApplicableTransTypes => 'Set',
214 ExecModule => 'QueueChange',
217 { Name => 'On Resolve', # loc
218 Description => 'Whenever a ticket is resolved', # loc
219 ApplicableTransTypes => 'Status',
220 ExecModule => 'StatusChange',
221 Argument => 'resolved'
224 { Name => 'On Reject', # loc
225 Description => 'Whenever a ticket is rejected', # loc
226 ApplicableTransTypes => 'Status',
227 ExecModule => 'StatusChange',
228 Argument => 'rejected'
231 { Name => 'User Defined', # loc
232 Description => 'Whenever a user-defined condition occurs', # loc
233 ApplicableTransTypes => 'Any',
234 ExecModule => 'UserDefined'
238 { Name => 'On Close', # loc
239 Description => 'Whenever a ticket is closed', # loc
240 ApplicableTransTypes => 'Status,Set',
241 ExecModule => 'CloseTicket',
243 { Name => 'On Reopen', # loc
244 Description => 'Whenever a ticket is reopened', # loc
245 ApplicableTransTypes => 'Status,Set',
246 ExecModule => 'ReopenTicket',
250 #{ Name => 'On Custom Field Transaction',
251 # Description => 'When a custom field is changed',
252 # ExecModule => 'CustomFieldTransaction',
253 # ApplicableTransTypes => 'Any',
255 #{ Name => 'On Custom Field Change',
256 # Description => 'When a custom field is changed to some value',
257 # ExecModule => 'CustomFieldChange',
258 # ApplicableTransTypes => 'Any',
265 Name => 'Blank', # loc
266 Description => 'A blank template', # loc
269 Name => 'Autoreply', # loc
270 Description => 'Plain text Autoresponse template', # loc
271 Content => 'Subject: AutoReply: {$Ticket->Subject}
276 This message has been automatically generated in response to the
277 creation of a trouble ticket regarding:
278 "{$Ticket->Subject()}",
279 a summary of which appears below.
281 There is no need to reply to this message right now. Your ticket has been
282 assigned an ID of { $Ticket->SubjectTag }.
284 Please include the string:
286 { $Ticket->SubjectTag }
288 in the subject line of all future correspondence about this issue. To do so,
289 you may reply to this message.
292 {$Ticket->QueueObj->CorrespondAddress()}
294 -------------------------------------------------------------------------
295 {$Transaction->Content()}
299 Name => 'Autoreply in HTML', # loc
300 Description => 'HTML Autoresponse template', # loc
301 Content => q[Subject: AutoReply: {$Ticket->Subject}
302 Content-Type: text/html
306 <p>This message has been automatically generated in response to the
307 creation of a trouble ticket regarding <b>{$Ticket->Subject()}</b>,
308 a summary of which appears below.</p>
310 <p>There is no need to reply to this message right now. Your ticket has been
311 assigned an ID of <b>{$Ticket->SubjectTag}</b>.</p>
313 <p>Please include the string <b>{$Ticket->SubjectTag}</b>
314 in the subject line of all future correspondence about this issue. To do so,
315 you may reply to this message.</p>
318 {$Ticket->QueueObj->CorrespondAddress()}</p>
321 {$Transaction->Content(Type => 'text/html')}
325 Name => 'Transaction', # loc
326 Description => 'Plain text transaction template', # loc
327 Content => 'RT-Attach-Message: yes
330 {$Transaction->CreatedAsString}: Request {$Ticket->id} was acted upon.
331 Transaction: {$Transaction->Description}
332 Queue: {$Ticket->QueueObj->Name}
333 Subject: {$Transaction->Subject || $Ticket->Subject || "(No subject given)"}
334 Owner: {$Ticket->OwnerObj->Name}
335 Requestors: {$Ticket->RequestorAddresses}
336 Status: {$Ticket->Status}
337 Ticket <URL: {RT->Config->Get(\'WebURL\')}Ticket/Display.html?id={$Ticket->id} >
340 {$Transaction->Content()}
344 Name => 'Transaction in HTML', # loc
345 Description => 'HTML transaction template', # loc
346 Content => 'RT-Attach-Message: yes
347 Content-Type: text/html
349 <b>{$Transaction->CreatedAsString}: Request <a href="{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}">{$Ticket->id}</a> was acted upon by {$Transaction->CreatorObj->Name}.</b>
352 <tr><td align="right"><b>Transaction:</b></td><td>{$Transaction->Description}</td></tr>
353 <tr><td align="right"><b>Queue:</b></td><td>{$Ticket->QueueObj->Name}</td></tr>
354 <tr><td align="right"><b>Subject:</b></td><td>{$Transaction->Subject || $Ticket->Subject || "(No subject given)"} </td></tr>
355 <tr><td align="right"><b>Owner:</b></td><td>{$Ticket->OwnerObj->Name}</td></tr>
356 <tr><td align="right"><b>Requestors:</b></td><td>{$Ticket->RequestorAddresses}</td></tr>
357 <tr><td align="right"><b>Status:</b></td><td>{$Ticket->Status}</td></tr>
358 <tr><td align="right"><b>Ticket URL:</b></td><td><a href="{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}">{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}</a></td></tr>
362 {$Transaction->Content( Type => "text/html")}
365 # Shadow the global templates of the same name to suppress duplicate
366 # notifications until rules is ripped out.
367 { Queue => "___Approvals",
368 Name => "Transaction in HTML",
371 { Queue => "___Approvals",
372 Name => "Transaction",
378 Name => 'Admin Correspondence', # loc
379 Description => 'Plain text admin correspondence template', # loc
380 Content => 'RT-Attach-Message: yes
383 <URL: {RT->Config->Get(\'WebURL\')}Ticket/Display.html?id={$Ticket->id} >
385 {$Transaction->Content()}
389 Name => 'Admin Correspondence in HTML', # loc
390 Description => 'HTML admin correspondence template', # loc
391 Content => 'RT-Attach-Message: yes
392 Content-Type: text/html
394 Ticket URL: <a href="{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}">{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}</a>
397 {$Transaction->Content(Type => "text/html");}
401 Name => 'Correspondence', # loc
402 Description => 'Plain text correspondence template', # loc
403 Content => 'RT-Attach-Message: yes
405 {$Transaction->Content()}
409 Name => 'Correspondence in HTML', # loc
410 Description => 'HTML correspondence template', # loc
411 Content => 'RT-Attach-Message: yes
412 Content-Type: text/html
414 {$Transaction->Content( Type => "text/html")}
418 Name => 'Admin Comment', # loc
419 Description => 'Plain text admin comment template', # loc
421 'Subject: [Comment] {my $s=($Transaction->Subject||$Ticket->Subject||""); $s =~ s/\\[Comment\\]\\s*//g; $s =~ s/^Re:\\s*//i; $s;}
422 RT-Attach-Message: yes
425 {RT->Config->Get(\'WebURL\')}Ticket/Display.html?id={$Ticket->id}
426 This is a comment. It is not sent to the Requestor(s):
428 {$Transaction->Content()}
432 Name => 'Admin Comment in HTML', # loc
433 Description => 'HTML admin comment template', # loc
435 'Subject: [Comment] {my $s=($Transaction->Subject||$Ticket->Subject||""); $s =~ s/\\[Comment\\]\\s*//g; $s =~ s/^Re:\\s*//i; $s;}
436 RT-Attach-Message: yes
437 Content-Type: text/html
439 <p>This is a comment about <a href="{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}">ticket {$Ticket->id}</a>. It is not sent to the Requestor(s):</p>
441 {$Transaction->Content(Type => "text/html")}
445 Name => 'Reminder', # loc
446 Description => 'Default reminder template', # loc
448 'Subject:{$Ticket->Subject} is due {$Ticket->DueObj->AsString}
450 This reminder is for ticket #{$Target = $Ticket->RefersTo->First->TargetObj;$Target->Id}.
452 {RT->Config->Get(\'WebURL\')}Ticket/Display.html?id={$Target->Id}
457 Name => 'Status Change', # loc
458 Description => 'Ticket status changed', # loc
459 Content => 'Subject: Status Changed to: {$Transaction->NewValue}
462 {RT->Config->Get(\'WebURL\')}Ticket/Display.html?id={$Ticket->id}
464 {$Transaction->Content()}
468 Name => 'Status Change in HTML', # loc
469 Description => 'HTML Ticket status changed', # loc
470 Content => 'Subject: Status Changed to: {$Transaction->NewValue}
471 Content-Type: text/html
473 <a href="{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}">{RT->Config->Get("WebURL")}Ticket/Display.html?id={$Ticket->id}</a>
476 {$Transaction->Content(Type => "text/html")}
482 Name => 'Resolved', # loc
483 Description => 'Ticket Resolved', # loc
484 Content => 'Subject: Resolved: {$Ticket->Subject}
486 According to our records, your request has been resolved. If you have any
487 further questions or concerns, please respond to this message.
491 Name => 'Resolved in HTML', # loc
492 Description => 'HTML Ticket Resolved', # loc
493 Content => 'Subject: Resolved: {$Ticket->Subject}
494 Content-Type: text/html
496 <p>According to our records, your request has been resolved. If you have any further questions or concerns, please respond to this message.</p>
499 { Queue => '___Approvals',
500 Name => "New Pending Approval", # loc
502 "Notify Owners and AdminCcs of new items pending their approval", # loc
503 Content => 'Subject: New Pending Approval: {$Ticket->Subject}
507 There is a new item pending your approval: "{$Ticket->Subject()}",
508 a summary of which appears below.
510 Please visit {RT->Config->Get(\'WebURL\')}Approvals/Display.html?id={$Ticket->id}
511 to approve or reject this ticket, or {RT->Config->Get(\'WebURL\')}Approvals/ to
512 batch-process all your pending approvals.
514 -------------------------------------------------------------------------
515 {$Transaction->Content()}
518 { Queue => '___Approvals',
519 Name => "New Pending Approval in HTML", # loc
520 Description => "Notify Owners and AdminCcs of new items pending their approval", # loc
521 Content => 'Subject: New Pending Approval: {$Ticket->Subject}
522 Content-Type: text/html
526 <p>There is a new item pending your approval: <b>{$Ticket->Subject()}</b>,
527 a summary of which appears below.</p>
529 <p>Please <a href="{RT->Config->Get(\'WebURL\')}Approvals/Display.html?id={$Ticket->id}">approve
530 or reject this ticket</a>, or visit the <a href="{RT->Config->Get(\'WebURL\')}Approvals/">approvals
531 overview</a> to batch-process all your pending approvals.</p>
534 {$Transaction->Content()}
537 { Queue => '___Approvals',
538 Name => "Approval Passed", # loc
540 "Notify Requestor of their ticket has been approved by some approver", # loc
541 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
545 Your ticket has been approved by { eval { $Approver->Name } }.
546 Other approvals may be pending.
548 Approver\'s notes: { $Notes }
551 { Queue => '___Approvals',
552 Name => "Approval Passed in HTML", # loc
554 "Notify Requestor of their ticket has been approved by some approver", # loc
555 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
556 Content-Type: text/html
560 <p>Your ticket has been approved by <b>{ eval { $Approver->Name } }</b>.
561 Other approvals may be pending.</p>
563 <p>Approver\'s notes:</p>
564 <blockquote>{ $Notes }</blockquote>
567 { Queue => '___Approvals',
568 Name => "All Approvals Passed", # loc
570 "Notify Requestor of their ticket has been approved by all approvers", # loc
571 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
575 Your ticket has been approved by { eval { $Approver->Name } }.
576 Its Owner may now start to act on it.
578 Approver\'s notes: { $Notes }
581 { Queue => '___Approvals',
582 Name => "All Approvals Passed in HTML", # loc
584 "Notify Requestor of their ticket has been approved by all approvers", # loc
585 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
586 Content-Type: text/html
590 <p>Your ticket has been approved by <b>{ eval { $Approver->Name } }</b>.
591 Its Owner may now start to act on it.</p>
593 <p>Approver\'s notes:</p>
594 <blockquote>{ $Notes }</blockquote>
597 { Queue => '___Approvals',
598 Name => "Approval Rejected", # loc
600 "Notify Owner of their rejected ticket", # loc
601 Content => 'Subject: Ticket Rejected: {$Ticket->Subject}
605 Your ticket has been rejected by { eval { $Approver->Name } }.
607 Approver\'s notes: { $Notes }
610 { Queue => '___Approvals',
611 Name => "Approval Rejected in HTML", # loc
613 "Notify Owner of their rejected ticket", # loc
614 Content => 'Subject: Ticket Rejected: {$Ticket->Subject}
615 Content-Type: text/html
619 <p>Your ticket has been rejected by <b>{ eval { $Approver->Name } }</b>.</p>
621 <p>Approver\'s notes:</p>
622 <blockquote>{ $Notes }</blockquote>
625 { Queue => '___Approvals',
626 Name => "Approval Ready for Owner", # loc
628 "Notify Owner of their ticket has been approved and is ready to be acted on", # loc
629 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
633 The ticket has been approved, you may now start to act on it.
637 { Queue => '___Approvals',
638 Name => "Approval Ready for Owner in HTML", # loc
640 "Notify Owner of their ticket has been approved and is ready to be acted on", # loc
641 Content => 'Subject: Ticket Approved: {$Ticket->Subject}
642 Content-Type: text/html
646 <p>The ticket has been approved, you may now start to act on it.</p>
651 Name => "Forward", # loc
652 Description => "Forwarded message", # loc
655 { $ForwardTransaction->Content =~ /\S/ ? $ForwardTransaction->Content : "This is a forward of transaction #".$Transaction->id." of ticket #". $Ticket->id }
659 Name => "Forward Ticket", # loc
660 Description => "Forwarded ticket message", # loc
663 { $ForwardTransaction->Content =~ /\S/ ? $ForwardTransaction->Content : "This is a forward of ticket #". $Ticket->id }
667 Name => "Error: unencrypted message", # loc
669 "Inform user that their unencrypted mail has been rejected", # loc
670 Content => q{Subject: RT requires that all incoming mail be encrypted
672 You received this message because RT received mail from you that was not encrypted. As such, it has been rejected.
676 Name => "Error: public key", # loc
678 "Inform user that he has problems with public key and couldn't recieve encrypted content", # loc
679 Content => q{Subject: We have no your public key or it's wrong
681 You received this message as we have no your public PGP key or we have a problem with your key. Inform the administrator about the problem.
685 Name => "Error to RT owner: public key", # loc
687 "Inform RT owner that user(s) have problems with public keys", # loc
688 Content => q{Subject: Some users have problems with public keys
690 You received this message as RT has problems with public keys of the following user:
692 foreach my $e ( @BadRecipients ) {
693 $OUT .= "* ". $e->{'Message'} ."\n";
698 Name => "Error: no private key", # loc
700 "Inform user that we received an encrypted email and we have no private keys to decrypt", # loc
701 Content => q{Subject: we received message we cannot decrypt
703 You sent an encrypted message with subject '{ $Message->head->get('Subject') }',
704 but we have no private key it's encrypted to.
706 Please, check that you encrypt messages with correct keys
707 or contact the system administrator.}
710 Name => "Error: bad encrypted data", # loc
712 "Inform user that a message he sent has invalid encryption data", # loc
713 Content => q{Subject: We received a message we cannot handle
715 You sent us a message that we cannot handle due to corrupted signature or encrypted block. we get the following error(s):
716 { foreach my $msg ( @Messages ) {
722 Name => "PasswordChange", # loc
724 "Inform user that his password has been reset", # loc
725 Content => q{Subject: [{RT->Config->Get('rtname')}] Password reset
729 Someone at {$ENV{'REMOTE_ADDR'}} requested a password reset for you on {RT->Config->Get('WebURL')}
731 Your new password is:
737 Name => 'Email Digest', # loc
738 Description => 'Email template for periodic notification digests', # loc
739 Content => q[Subject: RT Email Digest
747 Name => "Error: Missing dashboard", # loc
749 "Inform user that a dashboard he subscribed to is missing", # loc
750 Content => q{Subject: [{RT->Config->Get('rtname')}] Missing dashboard!
754 You are subscribed to a dashboard that is currently missing. Most likely, the dashboard was deleted.
756 RT will remove this subscription as it is no longer useful. Here's the information RT had about your subscription:
758 DashboardID: { $SubscriptionObj->SubValue('DashboardId') }
759 Frequency: { $SubscriptionObj->SubValue('Frequency') }
760 Hour: { $SubscriptionObj->SubValue('Hour') }
762 $SubscriptionObj->SubValue('Frequency') eq 'weekly'
763 ? "Day of week: " . $SubscriptionObj->SubValue('Dow')
764 : $SubscriptionObj->SubValue('Frequency') eq 'monthly'
765 ? "Day of month: " . $SubscriptionObj->SubValue('Dom')
771 Name => 'Custom Field Transaction',
772 Description => 'Custom field value changed',
773 Content => q[Subject: {$Transaction->BriefDescription()}
775 {RT->Config->Get('WebURL')}Ticket/Display.html?id={$Ticket->id}
777 {$Transaction->Content()}
784 { Description => 'On Comment Notify AdminCcs as Comment',
785 ScripCondition => 'On Comment',
786 ScripAction => 'Notify AdminCcs As Comment',
787 Template => 'Admin Comment in HTML' },
788 { Description => 'On Comment Notify Other Recipients as Comment',
789 ScripCondition => 'On Comment',
790 ScripAction => 'Notify Other Recipients As Comment',
791 Template => 'Correspondence in HTML' },
792 { Description => 'On Correspond Notify Owner and AdminCcs',
793 ScripCondition => 'On Correspond',
794 ScripAction => 'Notify Owner and AdminCcs',
795 Template => 'Admin Correspondence in HTML' },
796 # { Description => 'On Correspond Notify Other Recipients',
797 # ScripCondition => 'On Correspond',
798 # ScripAction => 'Notify Other Recipients',
799 # Template => 'Correspondence in HTML' },
800 # { Description => 'On Correspond Notify Requestors and Ccs',
801 # ScripCondition => 'On Correspond',
802 # ScripAction => 'Notify Requestors And Ccs',
803 # Template => 'Correspondence in HTML' },
804 { Description => 'On Correspond Open Inactive Tickets',
805 ScripCondition => 'On Correspond',
806 ScripAction => 'Open Inactive Tickets',
807 Template => 'Blank' },
808 { Description => 'On Create Autoreply To Requestors',
809 ScripCondition => 'On Create',
810 ScripAction => 'AutoReply To Requestors',
811 Template => 'AutoReply in HTML' },
812 { Description => 'On Create Notify Owner and AdminCcs',
813 ScripCondition => 'On Create',
814 ScripAction => 'Notify Owner and AdminCcs',
815 Template => 'Transaction in HTML' },
816 { Description => 'On Create Notify Ccs',
817 ScripCondition => 'On Create',
818 ScripAction => 'Notify Ccs',
819 Template => 'Correspondence in HTML' },
820 { Description => 'On Create Notify Other Recipients',
821 ScripCondition => 'On Create',
822 ScripAction => 'Notify Other Recipients',
823 Template => 'Correspondence in HTML' },
824 { Description => 'On Owner Change Notify Owner',
825 ScripCondition => 'On Owner Change',
826 ScripAction => 'Notify Owner',
827 Template => 'Transaction in HTML' },
828 { Description => 'On Resolve Notify Requestors',
829 ScripCondition => 'On Resolve',
830 ScripAction => 'Notify Requestors',
831 Template => 'Resolved in HTML' },
832 { Description => "On transaction, add any tags in the transaction's subject to the ticket's subject",
833 ScripCondition => 'On Transaction',
834 ScripAction => 'Extract Subject Tag',
835 Template => 'Blank' },
836 { Description => 'On Forward Transaction Send forwarded message',
837 ScripCondition => 'On Forward Transaction',
838 ScripAction => 'Send Forward',
839 Template => 'Forward' },
840 { Description => 'On Forward Ticket Send forwarded message',
841 ScripCondition => 'On Forward Ticket',
842 ScripAction => 'Send Forward',
843 Template => 'Forward Ticket' },
847 { UserId => 'root', # - principalid
848 Right => 'SuperUser', },
850 { GroupDomain => 'SystemInternal',
851 GroupType => 'privileged',
852 Right => 'ShowApprovalsTab', },
856 # Predefined searches
859 { Name => 'Search - My Tickets',
860 Description => '[_1] highest priority tickets I own', # loc
862 { Format => q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__id__</a>/TITLE:#',}
863 . q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__Subject__</a>/TITLE:Subject',}
864 . q{Priority, QueueName, ExtendedStatus},
865 Query => " Owner = '__CurrentUser__' AND ( Status = 'new' OR Status = 'open')",
866 OrderBy => 'Priority',
870 { Name => 'Search - Unowned Tickets',
871 Description => '[_1] newest unowned tickets', # loc
874 { Format => q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__id__</a>/TITLE:#',}
875 . q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__Subject__</a>/TITLE:Subject',}
876 . q{QueueName, ExtendedStatus, CreatedRelative, }
877 . q{'<A HREF="__WebPath__/Ticket/Display.html?Action=Take&id=__id__">__loc(Take)__</a>/TITLE:NBSP'},
878 Query => " Owner = 'Nobody' AND ( Status = 'new' OR Status = 'open')",
879 OrderBy => 'Created',
883 { Name => 'Search - Bookmarked Tickets',
884 Description => 'Bookmarked Tickets', #loc
886 { Format => q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__id__</a>/TITLE:#',}
887 . q{'<a href="__WebPath__/Ticket/Display.html?id=__id__">__Subject__</a>/TITLE:Subject',}
888 . q{Priority, QueueName, ExtendedStatus, Bookmark},
889 Query => "id = '__Bookmarked__'",
890 OrderBy => 'LastUpdated',
894 Name => 'HomepageSettings',
895 Description => 'HomepageSettings',
897 'body' => # loc_left_pair
901 name => 'My Tickets', # loc
905 name => 'Unowned Tickets' # loc
909 name => 'Bookmarked Tickets' # loc
913 name => 'QuickCreate' # loc
916 'sidebar' => # loc_left_pair
920 name => 'MyReminders' # loc
924 name => 'Quicksearch' # loc
928 name => 'Dashboards' # loc
932 name => 'RefreshHomepage' # loc
940 # Obsolete/erroneous scrips
942 # $Delete_Scrips{conditionname}{actionname}{templatename}
943 # exists, and the scrip was created by the system user, it
944 # will be deleted on upgrade. Lowercase all the names here.
948 'notify requestors and ccs' => { 'correspondence' => 1 },
949 'notify other recipients' => { 'correspondence' => 1 },
955 push @ScripActions, (
957 { Name => 'Extract Custom Field Values', # loc
958 Description => 'extract cf-values out of a message', # loc
959 ExecModule => 'ExtractCustomFieldValues' },
961 { Name => 'Extract Custom Field Values With Code in Template', # loc
962 Description => 'extract cf-values out of a message with a Text::Template template', # loc
963 ExecModule => 'ExtractCustomFieldValuesWithCodeInTemplate' }
969 Name => 'CustomFieldScannerExample', # loc
970 Description => 'Example Template for ExtractCustomFieldValues', # loc
971 Content => <<'EOTEXT'
973 # CF Name | Header name or "Body" | MatchString(re) | Postcmd | Options
975 #### Allowed Options:
977 # q - (quiet) Don't record a transaction for adding the custom field
979 # * - (wildcard) The MatchString regex should contain _two_
980 # capturing groups, the first of which is the CF name,
981 # the second of which is the value. If this option is
982 # given, the <cf-name> field is ignored.
986 # 1. Put the content of the "X-MI-Test" header into the "testcf"
988 # testcf|X-MI-Test|.*
990 # 2. Scan the body for Host:name and put name into the "bodycf" custom
992 # bodycf|Body|Host:\s*(\w+)
994 # 3. Scan the "X-MI-IP" header for an IP-Adresse and get the hostname
995 # by reverse-resolving it:
996 # Hostname|X-MI-IP|\d+\.\d+\.\d+\.\d+|use Socket; ($value) = gethostbyaddr(inet_aton($value),AF_INET);
998 # 4. scan the "CC" header for an many email addresses, and add them to
999 # a custom field named "parsedCCs". If "parsedCCs" is a multivalue
1000 # CF, then this should yield separate values for all email adress
1002 # parsedCCs|CC|.*|$value =~ s/^\s+//; $value =~ s/\s+$//;
1004 # 5. Looks for an "Email:" field in the body of the email, then loads
1005 # up that user and makes them privileged The blank first field
1006 # means the automatic CustomField setting is not invoked.
1007 # |Body|Email:\s*(.+)$|my $u = RT::User->new($RT::SystemUser); $u->LoadByEmail($value); $u->SetPrivileged(1)|
1009 # 6. Looks for any text of the form "Set CF Name: Value" in the body,
1010 # and sets the CF named "CF Name" to the given value, which may be
1011 # multi-line. The '*' option controls the wildcard nature of this
1014 # !Body!^Set ([^\n:]*?):\s*((?s).*?)(?:\Z|\n\Z|\n\n)!!*
1016 # 7. Looks for the regex anywhere in the headers and stores the match
1017 # in the AllHeaderSearch CF
1018 # AllHeaderSearch|Headers|Site:\s*(\w+)
1020 # 8. If you need to dynamically build your matching, and want to trigger on headers and body
1021 # and invode some arbitrary code like example 5
1024 # my $action = 'use My::Site; My::Site::SetSiteID( Ticket => $self->TicketObj, Site => $_ );';
1026 # for my $regex (My::Site::ValidRegexps) {
1027 # for my $from ('headers', 'body') {
1028 # $OUT .= join '~~',