Difference between revisions of "Add Custom Activity Log Action Macro"
(New page: This == Step 1. Upload New Action Macros== The first step is to add the new Action Macros. This is done via a data load since Service Desk does not provide a GUI method of create...) |
(→Step 2. Using the New Action Macros) |
||
| Line 29: | Line 29: | ||
== Step 2. Using the New [[Action Macros]]== | == Step 2. Using the New [[Action Macros]]== | ||
| + | [[Image:Event_Text.GIF|right|frame|r11.x Screenshot - Event Configuration]] | ||
To use these [[Action Macros]] you simply add them to the desired [[Event]]. Within the Text field of the [[Event]] you add the syntax you want to be added to the [[Activity Log]] | To use these [[Action Macros]] you simply add them to the desired [[Event]]. Within the Text field of the [[Event]] you add the syntax you want to be added to the [[Activity Log]] | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
---- | ---- | ||
<div align='center'><font color="red">To make corrections or additions to this article, select the ''edit'' tab above.<br> | <div align='center'><font color="red">To make corrections or additions to this article, select the ''edit'' tab above.<br> | ||
Revision as of 15:40, 11 February 2008
This
Step 1. Upload New Action Macros
The first step is to add the new Action Macros. This is done via a data load since Service Desk does not provide a GUI method of created or updating Action Macros.
Create a text file using the following syntax: <source lang=text>TABLE Spell_Macro del description fragment lock_object ob_type sym type usr_integer1 usr_integer2 usr_integer3 usr_string2 usr_string3 usr_string4
{ "0" ,"add an activty log listed in the event's \"Text Field\" to the request", "// add an activity log. Requires the macro be locked.\\0012int log_userid;\\0012log_userid = (uuid)"793ED69B4E87A545BD8E911834D829FC";\\0012 \\0012// get info from event to store in log description\\0012 \\0012string log;\\0012log = expand(event_tmpl.user_smag);\\0012 \\0012send_wait(0, this, \"log_event\", group_leader, log_userid, log);\\0012if (msg_error()) {\\0012 logf(ERROR, format(\"Macro event error '%s'\", msg[0]));\\0012}", "0" ,"cr" ,"Add a Custom Activity Log" ,"ACT", "" ,"" ,"" ,"" ,"" ,"" } { "0" ,"add an activty log listed in the event's \"Text Field\" to the change order", "// add an activity log. Requires the macro be locked.\\0012int log_userid;\\0012log_userid = (uuid)"793ED69B4E87A545BD8E911834D829FC";\\0012 \\0012// get info from event to store in log description\\0012 \\0012string log;\\0012log = expand(event_tmpl.user_smag);\\0012 \\0012send_wait(0, this, \"log_event\", group_leader, log_userid, log);\\0012if (msg_error()) {\\0012 logf(ERROR, format(\"Macro event error '%s'\", msg[0]));\\0012}", "0" ,"chg" ,"Add a Custom CHG Activity Log" ,"ACT", "" ,"" ,"" ,"" ,"" ,"" } { "0" ,"add an activty log listed in the event's \"Text Field\" to the issue", "// add an activity log. Requires the macro be locked.\\0012int log_userid;\\0012log_userid = (uuid)"793ED69B4E87A545BD8E911834D829FC";\\0012 \\0012// get info from event to store in log description\\0012 \\0012string log;\\0012log = expand(event_tmpl.user_smag);\\0012 \\0012send_wait(0, this, \"log_event\", group_leader, log_userid, log);\\0012if (msg_error()) {\\0012 logf(ERROR, format(\"Macro event error '%s'\", msg[0]));\\0012}", "0" ,"iss" ,"Add a Custom ISS Activity Log" ,"ACT", "" ,"" ,"" ,"" ,"" ,"" }</source>
Then run the following command:
pdm_load -f yourfile.txt -i -v
This process will add three new Action Macros.
Step 2. Using the New Action Macros
To use these Action Macros you simply add them to the desired Event. Within the Text field of the Event you add the syntax you want to be added to the Activity Log
To discuss or ask questions about this article, select the discussion tab above.