Maximo

 View Only
  • 1.  Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Tue February 20, 2024 08:23 AM

    My team has a requirement to add some conditions to display work order tasks in the WOTRACK app but it seems that the ootb relationship named SHOWTASKS is hard-coded and there in no way to customize it or replace it by another. We can tell from the ootb where clause that this is not the normal way tasks should be retrieved, so the real relationship must be defined somewhere else, most likely in the Java code.

    When we replace SHOWTASKS on the wotrack xml by another relationship having a different name, we encountered unexpected behaviors such as the task ID not being incremented when adding a new task or the task being created as a child work order. 

    Have anyone from the community managed to overcome this issue?



    ------------------------------
    Tahar Belaid
    Ville de Montréal
    ------------------------------


  • 2.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Wed February 21, 2024 05:22 AM

    The SHOWTASKS relationship that you modified, is it the one defined at the data source level with id="common_task_table"? If so, if the new relationship is properly defined, you shouldn't encounter any issues. However, if you declared the new relationship at the Tasks Table level (within the 'Relationship' tag), did you make sure to remove the data source (within the 'Data Source ID' tag)?

    Could you please provide more information, such as the query used for the new relationship and the section of the XML that you modified?



    ------------------------------
    ------------------------------
    Youssef HANBALI
    Architect Solutions IBM Maximo
    ------------------------------
    ------------------------------



  • 3.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Wed February 21, 2024 11:41 AM

    First, we created a new relationship called SHOWTASKS2 that should simply retrieve the workorder tasks. Its where clause is the following:

    parent=:wonum and siteid=:siteid and istask=:yes 

    Then, we replaced SHOWTASKS by SHOWTASKS2 in the common_task_table datasource definition in wotrack.xml

    <datasrc beanclass="psdi.webclient.beans.workorder.WOTasksBean" id="common_task_table" orderby="wosequence,taskid" relationship="SHOWTASKS2"/>

    We can now display work order tasks but if we add a new task, there is a strange behavior:

    • The task ID is empty and doesn't increment - it also must be mandatory but it isn't
    • After saving, the task is created as a child work order



    ------------------------------
    Tahar Belaid
    Ville de Montréal
    ------------------------------



  • 4.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Mon February 26, 2024 12:14 AM
    Edited by Juris Flugins Mon February 26, 2024 12:14 AM

    What if you try istask = 1 

    and also add

    and woclass = 'ACTIVITY'



    ------------------------------
    Juris Flugins
    ------------------------------



  • 5.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Mon February 26, 2024 05:57 AM

    If the requirement is to restrict the displayed data while maintaining the standard behavior (generating the taskid and making the field mandatory), two options are available:

    - Modify the existing SHOWTASKS relationship (not recommended by IBM) as this relationship is used in several Java processes.

    - Retain the same relationship and utilize data restriction configuration at the "Security Groups" application level.

    If it's a different requirement, please provide more details, and we can guide you towards a sustainable solution.



    ------------------------------
    ------------------------------
    Youssef HANBALI
    Architect Solutions IBM Maximo
    ------------------------------
    ------------------------------



  • 6.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Mon February 26, 2024 02:17 PM

    The requirement is to split work order tasks in two different tabs for particular PM work orders that use particular job plans:

    • a new tab was created to display tasks that use a specific classification - these tasks are displayed in a different way and must be separated from ordinary tasks. This part works fine
    • the regular tasks need to be displayed in the regular Plans tab. Therefore, we needed a solution to exclude the other tasks that are displayed in the custom tab and also maintain the standard behavior 


    ------------------------------
    Tahar Belaid
    Ville de Montréal
    ------------------------------



  • 7.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Mon February 26, 2024 04:31 PM

    In this case, have you attempted implementing the restriction at the application level? You can achieve this by incorporating a query into the presentation XML of the application. The query should be declared in the Application Restrictions field, which can be found in the Table Properties window under the "Advanced" tab.



    ------------------------------
    ------------------------------
    Youssef HANBALI
    Architect Solutions IBM Maximo
    ------------------------------
    ------------------------------



  • 8.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted Mon February 26, 2024 09:45 PM

    I've just tried it this way but unfortunately Maximo seems to completely ignore the restriction specifically on the tasks table because it's working on other tables such as the assignments table



    ------------------------------
    Tahar Belaid
    Ville de Montréal
    ------------------------------



  • 9.  RE: Unable to use a custom relationship to display tasks in Work Order Tracking application

    Posted 25 days ago

    Have you tried using "whereclause" like below:

    <datasrc beanclass="psdi.webclient.beans.workorder.WOTasksBean" id="common_task_table" orderby="wosequence,taskid" relationship="SHOWTASKS" whereclause="YOUR CONDITION"/>


    ------------------------------
    [Srikanth][Narala]
    [Maximo Specialist]
    [Melbourne]
    [Australia]
    ------------------------------