[SCCD] Automation Script function to check membership of security groups

I got a requirement to validate field when user are in specific security groups.

After googling, I found this entry http://www.learnsccd.com/2015/02/maximo-automation-script-validate-group.html (Thank you) . It explains how to validate group membership of current user login.

So I cut some part of code and make it as jython function for reuse next time.


s_secgroupset = “‘MAXADMIN’,”,’MAXREG'”
s_rem = “*****”

def ingroup():
mbosetMaxuser = MXServer.getMXServer().getMboSet(“MAXUSER”, mbo.getUserInfo())
mbosetMaxuser.setWhere(“userid = ‘” + user + “‘”)
mboMaxuser = mbosetMaxuser.moveFirst()

if (mboMaxuser is not None):
mbosetGroupUser = mboMaxuser.getMboSet(“GROUPUSER”)
mbosetGroupUser.setWhere(“groupname in (” + s_secgroupset + “)”)
print s_rem+”Where Clause: “+str(mbosetGroupUser.getCompleteWhere())
mboMaxGroup = mbosetGroupUser.moveFirst()

if (not mbosetGroupUser.isEmpty()):
print s_rem+”in groups”
return 1

if (mbosetGroupUser.isEmpty()):
print s_rem+”not in groups”
return 0


Read More

[SCCD] Auto Apply SLA

Most of my customer would like to auto apply SLA when they open tickets.

For this requirement, you can use Automation Script application to create Object Lunch Point and script to do it.

By configure as below

Read More

Read More

[SCCD] Set ticket to high priority for VIP person

In some case we need to set ticket priority align person’s information.

However internal priority is calculated by  impact and urgency from priority matrix.

This example will show you how to set high priority (or urgent) when effected person is VIP person.

Read More

Read More