Maximo Open Forum

 View Only
  • 1.  Maximo Inbound transaction on Inventory Usage

    Posted 09-06-2022 07:01
    Hi Everyone!

    We have a use case that an external system will send to Maximo Inventory Usage records with either COMPLETE or SHIPPED status. I already handled the changing of status via automation script (creating from ENTERED then to either COMPLETE or SHIPPED depending from xml). I just noticed that Maximo does not automatically create MATUSETRANS record even though the transaction was successful and it is already in COMPLETE status. Am I missing something or I should be creating this manually (automation script)? I was expecting that oob Maximo will handle it but if you could point me out to the right direction, I would be very much appreciative.



    Thanks!
    #Integrations
    #Inventory

    ------------------------------
    KM Cornista
    IBM
    ------------------------------


  • 2.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 09-06-2022 08:47
    I would need more info to help.

    1) What object structure are you using? Does it have the psdi.iface.app.invusage.MaxInvUseProcess processing class?
    2) Are you loading and completing it in the same transaction? IE it never exists in the database in an ENTERED status?
    3) How exactly are you completing the inventory usage record? You mentioned this "I already handled the changing of status via automation script"

    Status based records like this have to go through the proper change status flow to invoke the necessary logic. I've never tried to load an inventory usage and complete it before it's been saved. It's possible there's an issue with a relationship not returning results for example because the data hasn't been committed yet.

    It's also possible that how you're changing the inventory usage record isn't through the proper flow. If you have the right processing class (IE psdi.iface.app.invusage.MaxInvUseProcess) and you have the STATUS attribute as restricted, the framework should automatically process the status change properly. You shouldn't need to change the status via automation script.

    ------------------------------
    Steven Shull
    IBM
    ------------------------------



  • 3.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 09-07-2022 08:54
    Hi Steven!

    Thank you for taking a look at this.

    1. I am using a custom object structure specific for this use case. It does not have the processing class you mentioned. I shall try putting it in Inbound Processing Class after this.

    2-3. I created a logic in the script wherein I set the status to ENTERED first then used the changeStatus method to change it to COMPLETE status.

    I am kinda new to integration, so if I put the processing class in the Object Structure, does this mean that I can already omit the changeStatus part on my script?

    ------------------------------
    KM Cornista
    IBM
    ------------------------------



  • 4.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 09-07-2022 11:12

    Assuming the message has the STATUS attribute set correctly, you would not need to invoke the change status manually. Any statusable object (WORKORDER, PO, PR, INVUSE, etc.) in Maximo should have an inbound processing class of psdi.iface.mic.StatefulMicSetIn at a minimum. This class helps the integration handle the change status properly. 

    For all objects in Maximo (statusable or not) you want to identify if we have existing object structures and processing classes. In this case, the MXINVUSE object structure and the psdi.iface.app.invusage.MaxInvUseProcess processing class. This processing class extends from the StatefulMicSetIn so it has those capabilities plus some additional logic that is specific to Inventory usage.

    The reason you should duplicate existing object structures (or at least re-use the classes) is because we will often provide the necessary logic for handling a lot of the interactions that might be required to support this object properly. For example, on an Asset you need to be able to move the asset (change the parent or location) and there's special logic required to do that properly that we had to write in the processing class. On inventory usage, status progression is important but there's also some special logic for handling shipments and inventory split (when a sufficient balance doesn't exist to cover the required items). Without these processing classes, these operations may not be handled properly. 



    ------------------------------
    Steven Shull
    IBM
    ------------------------------



  • 5.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 09-07-2022 11:56
    Edited by KM Cornista 09-07-2022 11:58
    I tried commenting/disabling the changeStatus part in the script and adding the psdi.iface.app.invusage.MaxInvUseProcess to the processing class of my custom object structure for INVUSE > INVUSELINE > SHIPMENT. I also made the STATUS field RESTRICTED as per your advise. I included the SHIPMENT table in my OS because the external will also send details on this table that we also need to capture. See screenshots below.

    XML contains the required fields of INVUSE and INVUSELINES. I tried sending for ISSUE and the XML's status is in COMPLETE, but it did not process to COMPLETE. It was successfully changed to ENTERED tho as handled by the logic in the script. External will only be sending either COMPLETE or SHIPPED status value per use case.

    Can you give more info on how to properly use the processing class? Or perhaps I am missing something that I need to setup.




    ------------------------------
    KM Cornista
    IBM
    ------------------------------



  • 6.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 02-03-2023 15:14
    1. Don't restrict status field in OS
    2. Don't write any script for status change
    3. include the class file in custom OS Steven has mentioned
    4. While creating a custom OS, check whether any OOB OS is existing for the main object (invuse in this case), if yes duplicate that. 

    Now once your incoming xml comes with shipped status, it will create a record and maximo should automatically do the status change and update the status history table

    ------------------------------
    Subhransu Sekhar Sahoo
    Tata Consultancy Services
    ------------------------------



  • 7.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 03-29-2023 13:17

    Hello Sahoo,

    Regarding #1, Dont restrict Status field, it seems that the checkbox for it is read-only. Hence it is automatically restricted. Any way to bypass that so I can unrestrict it?



    ------------------------------
    KM Cornista
    IBM
    ------------------------------



  • 8.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 03-29-2023 15:49

    Status fields should always be restricted. This occurs due to the RESTRICTED field on MAXATTRIBUTE saying this should be restricted. Customers could check the override box and disable this for a specific object structure but this exists on the out of the box attributes for a reason. 

    If you don't restrict the field, the value you provide via MIF will get set directly on the record and not go through the proper change status process. 



    ------------------------------
    Steven Shull
    IBM
    ------------------------------



  • 9.  RE: Maximo Inbound transaction on Inventory Usage

    Posted 03-30-2023 03:03

    Got it, thanks Steven. We already migrated this to higher environment and for some reason, the status keeps on ENTERED even we sent COMPLETED status and with the processing class in it. In the Lower environment this works like you explain. I'll have to investigate further.



    ------------------------------
    KM Cornista
    IBM
    ------------------------------