Showing posts with label LOOKUP. Show all posts
Showing posts with label LOOKUP. Show all posts

Saturday, 15 August 2020

Conditional Lookup Functionality for List View Search using Automation Script isZombie() Method || IBM Maximo

Recently we had a requirement of conditional lookup for Maximo list view search. We have a custom column called sub-work type which is based on the value selected on the main work type attribute. This functionality on the application was working fine using table domain but it wasn't working on the list view in Maximo.

SO we developed a solution using conditional lookup automation script in Maximo list view search fields. First, we got the where clause of the current APP from memory in wclause variable, and then we got the work type i.e. CM or PM value using the split function. Then by using the zombie() method we set the work type value for a list where clause.

Object

WORKORDER

Type

ATTRIBUTE LAUNCH POINT (Jython)

Attribute

WOSUBTYPE

Name

WOSUBTYPE

Body

from psdi.common.context import UIContext

appName = mbo.getThisMboSet().getParentApp()

if appName in ('PLUSPWO','PLUSPWOCMP'):

#Get Where clause for list view search

    wclause = service.webclientsession().getCurrentApp().getResultsBean().getMboSet().getUserAndQbeWhere() 

 #Search worktype value of list view

    if mbo.isZombie():

         clause=wclause.split("worktype")[1].split("'")[1]

         listWhere="worktype='"+clause+"'"

Monday, 1 April 2019

Add Default Value to Lookup for Filtering | IBM Maximo



Export Lookup.xml

find lookup table tag and just paste default value tag into it, see below example:

    <table id="laborcraftrate" inputmode="readonly" selectmode="single">
        <tablebody displayrowsperpage="20" filterable="true" filterexpanded="true" id="laborcraftrate_lookup_tablebody">
            <tablecol dataattribute="orgid" id="laborcraftrate_lookup_tablebody_col_1" mxevent="selectrecord" mxevent_desc="Go To %1" sortable="true" type="link"/>
            <defaultvalue dataattribute="contractnum" defaulttype="query" id="laborcraftrate_lookup_tablebody_default" value="BEDFORD"/>
        </tablebody>
    </table>
import lookup.xml again.

we are done :)

Tuesday, 6 September 2016

Add a Combo-box Control in PR using ALN Domain or Object in Database Configuration | IBM Maximo

My client requirement is to have of combo-box (dropdown control) instead of domain(magnifier) for SHIPVIA in Purchase Requisition application Main tab.


Object is: PR
attribute is: SHIPVIA of PR object
DOMAINID in database configuration attach to SHIPVIA of PR object: SHIPVIA  (ALN domain name)

Wednesday, 31 August 2016

How to Add lookup to a custom field? | IBM Maximo

In this example we are going to create a new custom field in work order tracking application. And then we are going to attach a lookup to select existing people records.

  1. Create a new Table domain in Domain Application
    • Domain:    myPersonDomain
    • Object:        PERSON
    • Validation where clause:    personid = :myCustomField (same name as field in application)