IBM Support

How to display a message to indicate if there is any document associated with a Maximo record

Question & Answer


Question

How to display a message to indicate if there is any document associated with a Maximo record.

Answer

Please note that this process can apply to any other application within Maximo. You simply need to reference the correct Object for the application where you want to add this feature. You will need to create a different Relationship between the Object for the relevant application and the DOCLINKS object, as well as make the appropriate changes in the relevant Application in Application Designer.

The following example relates to Incidents records.

This requirement can be achieved using an Automation Script.



1. Go to the Database Configuration application.
- Open the Ticket object.
- Add one non-persistent field. For example: Attribute Name : DOCEXIST



- Select Action/ Apply Configuration Changes.

2. In the Application Designer application
- Open the Incident application.
- Add one Textbox Control - Open Textbox Properties dialog.
- Put Attribute as 'DOCEXIST' which was created in Step 1
- Set Input Mode as 'Readonly'


- Save

3. Go to the Automation Scripts application.
- Select Action / Create Script with Object Launch Point.
- Set Launch Point name, Description and Object like below.
- Set Object Event Condition. For example: Historyflag = 0


Then, check the 'Initialize' Event.

This Launch Point will be invoked when INCIDENT record is initialised.

- Click the 'Next' button.
- Set Script name as TESTSCT
- Set Script Language as 'jython'


- Click the 'Next' button. Put the Source Code like below.


* With this code, the Text Field (DOCEXIST)'s value will be set depending on the existence of associated document.

- Then click 'Create'.
- Change Status for TESTSCT to Active.

4. Go to the Incidents application.
- Open an Incident record.
- If there is any attachment associated with that incident, a message will then be shown like below.



If not, message will be shown like below.



N.B.: The message can be changed to your preference.

[{"Product":{"code":"SSLKT6","label":"IBM Maximo Asset Management"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.5","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Document Information

Modified date:
17 June 2018

UID

swg21667710