Select Page
< All Topics
Print

Map Tooltip Configuration

Map Tooltip Configuration

Feb 21, 2020 | 0 comments

Clicking directly on a map feature will open and Info Card, like this:

In Maximo, spatial selected manhole

This card, or tooltip, is configurable, and can be defined for every MapEngine layer. In the AGMAPLAYERS table you’ll find a field called TTJSON. Every layer can have a JSON object stored in this field, containing the information about fields to display in the tooltip and where to find them.

This is the syntax you should use: 

{“Display name”: “key|fieldname”, … } 

There are 4 different types of keys that can be used—M, MS, G, and F. 

M – Normal Maximo tables (e.g. WORKORDER, ASSET, LOCATIONS) 

MS – Maximo Spec tables (e.g. WORKORDERSPEC, ASSETSPEC, LOCATIONSPEC) 

G – GIS data 

F – html from a JavaScript function – where the function must take parameters key1 and maxtype (A, L, W) and return the html to be put in the field value.

T – plain text. For example, “Type”:“T|Manhole” would display “Type:  Manhole” in the tooltip 

Fieldname specifies the name of the field in the table, or the function name. 

Example JSON:  

Here are a few examples of how to configure the tooltip.  [BTW, an empty JSON object can be used to disable tooltips for the layer.]

Tooltip with Maximo asset specifications:

{"Description":"M|DESCRIPTION", "Manufacturer":"MS|MANUFACT","Main Size":"MS|MAINSIZE","Open WOs":"F|agGetNumberOfOpenWOs",”Type”:”T|Manhole”}

Looks like this:

 

Tooltip on an asset with open work order count display:

{"Asset Number":"M|ASSETNUM","Description":"M|DESCRIPTION", "Open WOs":"F|agGetNumberOfOpenWOs", "Open PMs":"F|agGetNumberOfOpenPMs"}

This looks like this:

Gate Valve Tooltip

 

Tooltip for a Service Request:

{"Ticket #":"M|TICKETID","Description":"M|DESCRIPTION","Status":"M|STATUS","Location":"M|LOCATION","Asset":"M|ASSETNUM","Report data":"M|REPORTDATE"}

Service Request Tooltip

…looks like this:

 

Table of Contents