Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Sign up

Sign up | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_Related Related Topics sp_TopicIcon
EZMax Mobile Condenses my URLNAME in Automation Script
EZMAX removes spaces in the Docinfo.URLNAME
August 30, 2021
1:24 pm
Avatar
laserlite
New Member
Members
Forum Posts: 1
Member Since:
July 13, 2016
sp_UserOfflineSmall Offline

I have modified IBM’s OOTB Script ‘OSACTION.MXAPIINSPRESULT.CREATEWO’ to allow the attachments to be part of the follow-up WO. 

    wonum = newWO.getString(‘wonum’)
    test = newWO.getLong(“WORKORDERID”)
    logger.info(“This is the WORKORDERID ” + str(test))
    for i in range(0, attachmentCount):    
 
        logger.info(“This is the attachment count in this loop ” + str(attachmentCount))
        attachmentSet.setOrderBy(‘DOCLINKSID’)
        attachmentSet.reset()
        attachment = attachmentSet.getMbo(i)
 
        logger.info(“This is the attachment ADDINFO ” + str(attachment.getBoolean(“ADDINFO”)))  
        logger.info(“This is the attachment DESCRIPTION ” +attachment.getString(“DESCRIPTION”))
        logger.info(“This is the attachment DOCINFOID ” + str(attachment.getLong(“DOCINFOID”)))   
        logger.info(“This is the attachment DOCLINKSID ” + str(attachment.getLong(“DOCLINKSID”)))
        logger.info(“This is the attachment DOCTYPE ” + attachment.getString(“DOCTYPE”))        
        logger.info(“This is the attachment DOCUMENT ” + attachment.getString(“DOCUMENT”))
        logger.info(“This is the attachment DOCUMENTDATA ” + attachment.getString(“DOCUMENTDATA”))
        logger.info(“This is the attachment NEWURLNAME ” + attachment.getString(“NEWURLNAME”)) 
        logger.info(“This is the attachment OWNERID ” + str(attachment.getLong(“OWNERID”)))
        logger.info(“This is the attachment OWNERTABLE ” + attachment.getString(“OWNERTABLE”))
        logger.info(“This is the attachment UPLOAD ” + str(attachment.getBoolean(“UPLOAD”)))
        logger.info(“This is the attachment URLNAME ” + attachment.getString(“URLNAME”))
        logger.info(“This is the attachment URLTYPE ” + attachment.getString(“URLTYPE”))       
 
        doclinksMboSet = newWO.getMboSet(“DOCLINKS”)
        woattachment = doclinksMboSet.add()
        woattachment.setValue(“OWNERTABLE”, “WORKORDER”)
        woattachment.setValue(“OWNERID”, test)
        woattachment.setValue(“URLTYPE”, “FILE”)        
        woattachment.setValue(“URLNAME”, attachment.getString(“URLNAME”) )
        woattachment.setValue(“NEWURLNAME”, attachment.getString(“URLNAME”) )
        woattachment.setValue(“DOCTYPE”, attachment.getString(“DOCTYPE”))
        woattachment.setValue(“ADDINFO”, True)
        woattachment.setValue(“DESCRIPTION”, attachment.getString(“DESCRIPTION”)  )
        woattachment.setValue(“DOCUMENT”,attachment.getString(“DOCUMENT”))
        doclinksMboSet.save()
        doclinksMboSet.close()
    
This works as expected in Maximo but if there is a space in the file name of the image from a file uploaded it strips the spaces out of the URL when using EZMAXmobile. Also it changes the the URL on images from the cmaera. 
Forum Timezone: America/New_York

Most Users Ever Online: 54

Currently Online:
1 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

sun kim: 60

madd0g17: 59

v.barsamov: 51

cgregory: 45

Maximofresher: 45

matta0990: 33

Member Stats:

Guest Posters: 0

Members: 14318

Moderators: 0

Admins: 3

Forum Stats:

Groups: 1

Forums: 8

Topics: 1578

Posts: 4293

Newest Members:

Marc Bannister, Joseph Tyler, Robert Gonzales, Tarek Marzouk, Tarek Marzouk, Ivan Garza

Administrators: Chon: 1118, kristensibilia: 0, Joe Grassia: 0