08-26-2010 07:27 AM
During the process of writing notification message bodies and activity action, I have found some "warts" in the process. For instance, output of arrays is pretty limited. It does not appear to work to put an array, and other information, into the description field of an activity action (this is the info that is logged into the historic activity log tab of an incident).
I had similar tough times dealing with arrays in email messages - I ended up deleting them from the messages in an effort to streamline the messages.
I am now trying to figure out if I can even put an array into a condition for one of these things. For instance, I have the condition:
not null(description in $L.file.save) and not same(description in $L.file.save, nullsub(description in $L.file, "BLANK"))
so that I can log the previous value of description in the log. But I am not seeing anything appear.
Is there any special trick to this kind of condition that I am missing?
Solved! Go to Solution.
08-26-2010 07:40 AM
What type of ticket are you trying to do this with? The reason I ask is because I am able to make it work for Incidents with the following condition (hint: action is the name of the description field).
not null(action in $L.file.save) and not same(action in $L.file.save, nullsub(action in $L.file, "BLANK"))
As for the description in your activity action, that may be tricky to get right but I have a feeling your get it.
So do you want to talk about this ... "I had similar tough times dealing with arrays in email messages - I ended up deleting them from the messages in an effort to streamline the messages." Arrays in emails aren't very fun to work with, but they can be done in a way that makes them useful. If you want to try to get them in your messages, let me know where you were having issues and I will be glad to try to help with it.
08-26-2010 09:58 AM
I am trying to get my activity action on a probsummary Update Activities activity actions. This is the category, from what I can tell, associated with IM.update.incident.It appears that, for that entry that I sent, I either didn't read my notes properly, or I have a problem in yet another action where the name is wrong. Thanks for pointing out the action, not description, Sigh.
I'm sure THAT will fix that one.
As for the other tough times, we were trying in an early test of notification msg bodies to display the description field as well as the solution field. We were ending up with partial information being displayed. However, what we decided was that it wasn't really essential to the message - because the message has the URL for the ticket in it. People can just go there. So we trimmed out a lot of the "extraneous" information to streamline the messages.
I _think_ that the fix to the variable name should solve the problem I was seeing here.
As far as you know, though, I can use array variables in condtions using null() and same()?
08-26-2010 10:18 AM
It's always something simple like the wrong name or a missing $L.file. You can use the null() and same() functions on arrays, and 99% of the time things will work out for you.
As for the description and solution in notifications, these can be done in a very simple way. When you create your form for the notification, you will of course be using a text area for these fields. Once they are there, you need to go to the predesign page for the form, and select "Format Details" from the menu. Here you will need to set the the following values to make them work.
Length: A value greater then what you would expect to find in the field (I use 1000)
This creates a text area that will expand with the data that is entered into it. If this isn't the last line on your form (which is wouldn't be if you have both), you want to put the next item only one "Line" down.
This image is my closure format for Incidents, and it contains the Description and resolution at the bottom.
When the mail comes out it will look something like the following ...
Contact Name: Test Email
Location: Test Area
This is a test email to show the formating.
The description field will scroll to as many lines as needed.
The resolution label will end up one line down from the end of the description because of how it was set in the Format Details.
This area will also scroll to whatever length is needed.
Hope this helps and gives you some ideas on what you can do with your notifications.
08-26-2010 11:05 AM
It's no problem ... As always I am just glad I can help out. I am assuming that changing your activity action from "description" to "action" fixed the original issue?
08-26-2010 11:17 AM
Yes, that fixed it right up. I still don't know if I tried to use something from another activity action or just had fingers typing something different than the eyes were seeing. Once I finish entering all the actions, I'll have to go back and make certain. But things are looking pretty good right now, thanks to your help.