Maximo

 View Only

How to Relate WORKORDER and INSPFIELD objects via INSPQUESTION object to display results in WORK ORDER TRACKING Application

  • 1.  How to Relate WORKORDER and INSPFIELD objects via INSPQUESTION object to display results in WORK ORDER TRACKING Application

    Posted 5 hours ago
    Hello ,
    I am trying to add a new tab in work order tracking application to display the Inspection results , The Questions and the responses received against each question for the specific Workorder opened.
     
    An inspection form may contain 1 or more Group Header questions and each question may have 1 or more data entry questions to collect response.
     
    I have referred the Failure code application approach of passing param value from one table to another table to dynamically the display the data for the highlighted record.
     
    so, I have a created a table to display Inspquestion related data. I've created maxrelationship from workorder to inspquestion involving the inspectionresult table to fetch the dataset and used this relation as the source for this table.
     
    Relationship > INSPQUESTION : FROM WORKORDER TO INSPQUESTION
    inspformnum=:inspformnum and revision =(select revision from inspectionresult where inspformnum=inspformnum and orgid=:orgid and referenceobjectid=:wonum) and orgid=:orgid
     
    snippet from application xml:
     
     <table relationship="INSPQUESTION" id="question_data" label="Questions" >
    <tablebody displayrowsperpage="10" filterable="true" id="question_data_tablebody">
    <tablecol filterable="false" id="question_data_tablebody_1" mxevent="toggledetailstate" mxevent_desc="Show Detail" sortable="false" type="event"/>
    <tablecol dataattribute="INSPQUESTIONNUM" id="question_data_tablebody_2" inputmode="readonly" label="Question">
    <textbox id="question_data_tablebody_2_1" lookup="failurecode"/>
    </tablecol>
    <tablecol dataattribute="DESCRIPTION" id="question_data_tablebody_3" label="Description" showfilterfield="true" sortable="false">
    <textbox id="question_data_tablebody_3_1" lookup="longdesc"/>
    </tablecol>
    </tablebody>
    </table>
    As a next step, I have created another table to display Inspfield related data based on the inspquestion highlighted or selected in Question table above.
    Here I am not able to figure out a way to bind inspquestionnum to inspfield using maxrelationship 
     
    I have initially developed this relationship which fetches all the data entry questions from inspfield. But I want to segregate the results based on inspquestionnum which is not available on workorder object.
     
    relationship from WORKORDER TO INSPFIELD:
    inspformnum=:inspformnum and 
    revision=(select revision from inspectionresult where inspformnum=:inspformnum and referenceobjectid=:wonum orgid=:orgid) and orgid=:orgid
     
     
    Any pointers would be really helpful. 

    Thanks



    ------------------------------
    Meghana Siriveli
    ------------------------------