Maximo Open Forum

 View Only
  • 1.  Adding Fields to Communication Templates

    Posted 06-29-2024 17:58

    Hello all, concerning adding fields to communication templates:

    1. Is it possible to add more fields as options to this box? 
    2. Or, if possible, how do you add fields to a communication template that is not here?

    Thank you,


    #Administration
    #EverythingMaximo

    ------------------------------
    Danny Richardson
    Maximo Administrator Manager
    Technimark LLC
    ------------------------------


  • 2.  RE: Adding Fields to Communication Templates

    Posted 07-01-2024 08:47

    That's just pulling everything that's in the database.  In the screenshot you've provided, you're using WORKORDER as the base table for the Communication Template, so it is showing you all the attributes of the WORKORDER table.  If you scroll down within that box, after the list of Attributes you would see a list of all the Relationships -- so, for example, if you needed the Description of the Asset, you could scroll down past the list of Attributes, find the ASSET relationship, click the plus sign beside it, and then pick the Description attribute there.

    If you need more fields, well, anything that the database recognizes is there, aka anything that was added through the Database Configuration application, should show up there.



    ------------------------------
    Travis Herron
    Pensacola Christian College
    ------------------------------



  • 3.  RE: Adding Fields to Communication Templates

    Posted 07-01-2024 09:07

    Hi @Daniel Richardson!

    Like, as travis says, the first part are the workorder fields and the next is the related tables. So, if you need to show something that you don't have now, for example, some data from a materials receipt linked to a WO, you can create a new relationship to the receipts table (MATRECTRANS) and show some data. You can do that whenever you want. If you tell me that you need to consult, I can tell you how to do it.

    Regards!



    ------------------------------
    Martin Fabra
    ARSAT S.A. - Actively seeking employment
    ------------------------------



  • 4.  RE: Adding Fields to Communication Templates

    Posted 07-01-2024 13:11

    Hi Danny,

    As Travis and Martin have said, the fields listed there are a combination of the attributes from the Applies To object from the communication template and then all the relationships defined for that object and then their attributes. Also as Martin noted, you can add custom relationships on the Applies To object in the Database Configuration application and they will then show up in that dialog.

    Also worth noting is that that dialog is just a helper to build the format of colon (:) + (optional relationship name plus a period) attribute name. So assuming WORKORDER is your Applies To object, :wonum will be replaced with the work order number from the current work order object, likewise :description will be replaced by the description.  To access a related field you simply refer to the relationship name and then dot (.) the attribute name. For example there is a relationship called ASSET on the WORKORDER object that defines a relationship between the WORKORDER and ASSET table, so to get the asset description I can use :asset.description 

     Under the covers it is use the psdi.mbo.SqlFormat class to format the text of your communication template by binding the cololn (:) values with their corresponding Mbo value.  It is a little beyond what you are asking here, but if you want more details you can read this: https://www.sharptree.io/blog/2022/2022-01-31-sql-format/

    Regards,

    Jason



    ------------------------------
    Jason VenHuizen
    Sharptree
    ------------------------------



  • 5.  RE: Adding Fields to Communication Templates

    Posted 07-01-2024 22:07

    Hi Danny,

    Your question is best answered with a question.  What is the field that you wish to add?

    Let's take Q1.  In the following screenshot from the Work Order Tracking application, you want to include the Work Type field.  In the first instance, you can use the field help and it shows WORKORDER.WORKTYPE.  So, on the tree as it starts with WORKORDER, that's the first part, then simply looking down the tree look for WORKTYPE.  On selection, it will return :WORKTYPE.  As there is no period (fullstop), it means that it is a field belonging to the object WORKORDER.

    Now, looking at the Asset field and more specifically, the Asset's description, you can see that it is ASSET.DESCRIPTION.  As the first part is not WORKORDER it means that you are access the description via a relationship.

    If you scroll down, you will see an arrow with the name of the relationship ASSET and once you open that and scroll down on that part of the tree, you will come across DESCRIPTION.  Once you select that it will return :ASSET.DESCRIPTION.  I hope that you can see the difference between the first example and the second.  That answers Q1.

    Now for Q2.  How you do add more fields.  It's more around "Is there already an existing relationship or not?"  This is a moot answer if you are simply referencing a field on a relationship that already exists as that is automatically added to the tree once you have added the field to the object in Maximo.  If there is no relationship to a field, then you simply need to go Database Configuration, select the main object i.e. WORKORDER, then select the Relationships tab, add the new one, come back to the comm template and it's available immediately.  Please note that usually, this has to be a 1:1 not a 1:N relationship.

    Back to my opening.  These are always easier to answer if you can outline what you trying to achieve.



    ------------------------------
    Craig Kokay
    Principal Consultant
    COSOL

    email: craig.kokay@cosol.global
    #IBMChampion
    ------------------------------