Quantcast
Channel: Ivanti User Community: Message List
Viewing all articles
Browse latest Browse all 12704

Re: Getting 2 notes details to email via reminders

$
0
0

old thread, but this is useful.

 

import System
static def GetAttributeValue(Incident):          HTML1 = '<br><table bgcolor="#F7E9FF" cellpadding="5" style="font-family:verdana; font-size:11;">'          HTML2 = '<tr><td><a href="http://servicedesk/WebAccess/wd/object/invokeFunction.rails?class_name=IncidentManagement.Incident&key=' + Incident.Guid + '&function_name=AddNote">Click here</a> to add a note to this ticket.<br><font color="grey">DO NOT reply to this email message.<font color="black">' + '</td></tr></table>'          Date = ""          Time = ""          Nice = ""          Value = ""          NoteTitle = ""          NoteDetail = ""          if Incident.Notes.Count < 1:          Value = ''          HTML1 = ''          HTML2 = ''          Value += HTML1          for Note in Incident.Notes:          NoteTitle = ""          NoteDetail = ""          if Note.Title != null:          NoteTitle = '<font color="grey"> - ' + Note.Title + '</font>'          if Note.Text != null:          NoteDetail = NoteDetail = Note.Text          Date = Note.CreationDate.ToLocalTime().ToString("ddd MMM d, yyyy")          Time = Note.CreationDate.ToLocalTime().ToString("h:mm tt")          Nice = Date + ' ' + Time          Value += '<tr><td><b>Note '+ Note.SerialNumber + ':</b> '+ Nice + '<br>'          Value += 'by '+ Note.RaiseUser.Title + NoteTitle + '<br>'          Value += NoteDetail + '</td></tr>'          Value += HTML2          return Value

 

screen shot of email:

notes email.PNG


Viewing all articles
Browse latest Browse all 12704

Trending Articles