In order to let Spatial know which (and where) GIS attributes are to be saved in Maximo from our Feature Class and vice versa, we need to use the JSON Mapping application.
To make things shorter, we'll be showing how to make this configuration in a Maximo environment with an already configured Map Manager record. So, first of all, please make sure that you have a Map Manager record with all the basics set up (such as Map Services, Service Layers etc).
There are two types of JSON Mapping records, inbound and outbound. Their names are pretty suggestive, indicating the direction of the data flow. In this example I'll be configuring an inbound JSON mapper:
1. Open your JSON Mapping application and create a new record.
2. Fill out the following fields:
a. Give it a name that makes it easy to identify your record later. In my case, since I'll be working with hydrant records, I'm naming it "WHYD INBOUND".
b. In Map Manager, my hydrants are configured as assets, so I'll populate the Object Structure field as ARCGISASSET.
c. Leave the direction as Inbound.
3. Now, in order to fill the JSON Data field, we'll need to get a query URL from our Map Service, so let's open our Map Service and get to the layer which will be mapped.
4. Scroll down the layer's page and click Query.
5. We just need to produce a query capable of returning at least one JSON object, which will allow our JSON Mapper to get its attribute structure. Fill out the following fields:
a. Where: OBJECTID<10
b. Out Fields: *
c. Format: JSON
d. Leave the other fields as they are.
e. Click the Query(GET) button.
6. Copy the URL from your browser's address bar and paste it into the URL field of your JSON mapper and tab out of it. Notice that it will fill the JSON Data field automatically.
7. Click Save.
8. Go to the Properties tab.
9. Now we'll have to drill down through the data layers until we get to the attributes, so click Map More Objects.
10. In the Select More Objects dialog, select the Asset object.
11. Now, click on the magnifying glass next to the Property Path field of the second line that was just created.
12. In the Select Value dialog, select the "//features" item.
13. We need to go down one more layer in order to get to our object attributes. So click Map More Objects, select the Asset object and then click on the magnifying glass. Now you'll have to select the "//features/attributes" item.
14. Your Properties tab should look like this:
15. Now let's map our attributes from the JSON object to our Maximo object by clicking New Rown under the "JSON Properties Mapping for Process Order 3" section (please note that you need to have the third row from the first section selected).
16. In this case, I'll map my JSON object's FacilityID (source property) into my Asset's FacilityID (target attribute) attribute (which was created manually through the Database Configuration app). This will consolidate the relationship established in my service layer's configuration for this Feature Class in Map Manager.
17. Now let's map some Spatial specific attributes, which are required to link our Asset record to the Map Feature. In this example, we are "hardcoding" the PLUSSISGIS and PLUSSFEATURECLASS attributes with values that will satisfy our requirements to complete this example (these values could be hardcoded or not in your case).
18. Since I don't have site information in my Feature Class, I'll hardcode the SITEID attribute as well.
19. Let's map the remaining attributes for this example and map:
(JSON's obj attribute)->(Target attribute in Maximo)
b. "Water hydrant manufactured by "+$.MANUFACTURER->DESCRIPTION
20. Click Save.
21. Go to Map Manager and open your map record which contains the Layer you are configuring, then open the Service Layer which corresponds to the feature class we are mapping.
22. Expand its line and scroll all the way down to the JSON Map Names section.
23. So now let's put our inbound JSON mapper in the Inbound JSON Mapper Name field.
24. Done! Your inbound JSON mapper is created and properly configured in your Map Manager record.