Aras Innovator Platform

Creating Graph Views

Graph Views are defined using Graph View Definition Items, found under Administration --> Configuration --> Graph Navigation --> Graph View Definitions in the TOC.

A Graph View can display data constrained by a Query Definition (Query Based) or can display all data related to a root item if you create an Ad Hoc Query.

Graph View Definitions (GVD) are supported by the following ItemTypes:

  • Node View Definition(NVD)
  • Node Type(NT)
  • Connector View Definition(CVD)
  • Connector Types(CT)
  • View Card(VC)
  • System Default Card

Ad-hoc GVDs allow users to freely navigate items and item relationships based on the selected root item.

Use the following procedure:

  1. In the TOC go to Administration>Configuration>Graph Navigation>Graph View Definitions. The following menu appears.
  2. Click Create New Graph View Definition. The Graph View Definition screen appears.
  3. Enter a unique Namefor the GVD.
  4. Save the Graph View Definition.
  5. Click the Add ItemTypes icon

    in the Item Types Relationship Tab and pick the ItemTypes that will be permitted as root ItemTypes for the GVD. The following example uses the Part ItemType from which you can generate the example Graph View.

    Note
    ItemType entries are not required for Ad-hoc GVDs. When they are not provided, the GVD can be used with ANY ItemType. The ItemType entries provide a way to restrict the root node. However, it does not restrict which ItemTypes can be reached from the root node.

  6. Click the Default View Cards relationship tab to associate ItemTypes in the Graph View with specific View Cards.
  7. Click the Add View Cards icon

    to add an existing view card to the Graph View.

    Click the New View Card icon

    to add a new view card to the Graph View.

    Click the New gn_GVDefaultCard

    icon to create a View Card. A new row appears.

  8. Double-click the ItemType ID field and click the ellipses to select the ItemType to associate with the Part default view card. The ItemType Search dialog box appears.

Parts in the example Graph View use the Part Card. Graph View Definition Default View Cards take precedent over System Default Cards.

Query based GVDs enable users to view items, relationships, and data that are explicitly defined within a Query Definition. This can be useful when there is a need to filter or focus the user’s interaction on specific items and details.

Creating a Query Definition

Before creating a Query-based Graph View Definition, you must first create the Query Definition. For information on how to create a Query Definition, refer to the Query Builder Guide. Specifically, Section 2 walks you through creating a sample Query Definition. Use a carefully configured Query Definition to automatically generate the necessary underlying items for the Graph View Definition.

Note
Only item properties selected in the Query Definition can be mapped to node and connector view cards. Mapping of Query Item properties to View Card content bindings is handled by the Node Type and Connector Type ItemTypes.

Creating a Query-Based Graph View Definition

Use the following procedure to create a Query Based Graph View Definition:

  1. Create a Query Definition using the Query Builder Application.
  2. Create a new Graph View Definition item, specifying a unique Name and selecting the desired Query Definition.
  3. Save the Graph View Definition. The following popup dialog appears:
  4. Clicking the generate button runs a method that generates all underlying ItemTypes and Relationships and maps them to the query items of the Query Definition. If you select the Treat Relationship As Connectoroption, all relationships in the Query Definition are treated as connectors. Otherwise, each relationship is drawn as a separate node and connectors will be implicit. If you select the Generate View Cards For Each Query Itema unique view card is generated for each Query Item and added as a GVD Default View Card. The generated view cards will have a row for each property selected for the Query Item in the Query Definition.
  5. In the Default View Cards Relationship Tab, you may associate ItemTypes in the Graph View with specific View Cards. Click on the New Relationship icon to pick a View Card. Then select the ItemType to associate the View Card with in the ItemType ID cell..
  6. In the Nodes Relationship Tab you can view and edit generated Node Types which are associated with the respective Query Item. Click on a Node Type to be directed to the Node Type Form. You may also associate an existing Node View Definition to a specific Node within the relationship tab.
  7. From a Node Type Form, you may add, remove, or edit Node Type Properties. The Name of a property is used to bind data to a View Card. See Section 4.1 for an example of a View Card that uses the content_bindingattributeto refer to Node Type content. The Value Templateis used to define the content to display. The Value Template supports both static and generated content. In Figure 11, observe that both name and state use Value Templates which refer to static and generated data.
  8. Note
    Append ‘@’ for System ItemType properties. i.e. {@type}

  9. If desired, repeat Steps 6 and 7 for the generated connectors and Connector Types found in the Connectors Relationship Tab.
Note
The entries required for the ItemTypes relationship of the GVD are generated automatically for Query-based GVDs. The requirements for modifying these entries for Query-based GVDs is currently outside the scope of this guide.

Use the following procedure:

  1. Navigate to AdministrationConfiguration Graph Navigation View Cardsinthe TOC. The View Cards menu appears.
  2. Click Create New View Card. The View Card window appears.
  3. Figure 12

  4. Specify a unique Name.
  5. Specify the View Card Template Definition. See Section 4.1 for supported attributes and sample Templates.

Use the following procedure to create either a Node View or a Connector View Definition:

  1. Click AdministrationConfiguration Graph Navigation->Node View Definitionsinthe TOC. The following menu appears:
  2. Select Create NewNode View Definition.The Node View Definition window appears:
  3. Specify a unique Name.
  4. Click the Add View Cards icon

    on the View Cards tab. The Search dialog box appears.

  5. Enter p* in the Name column and click the Search icon:
  6. Select Part Card.
  7. Click

    and

    to save and unclaim the NVD.

To enable a user to open a Graph View on a specific ItemType, navigate to the desired ItemType and on the Actions tab, add an Action that runs the gn_ShowGraph Method. When this action is applied to an item instance, it will generate a Graph View in a new tab. If no available Graph View Definitions have been created by an administrator, a system default Ad Hoc Graph View will always be available.

When you create and export packages that include graph views, it is important to include any associated items with the top-level Graph View definition. You may need to expose some of these items in the TOC to package them:

  • gn_GraphViewDefinition
  • gn_ViewCard
  • gn_ConnectorType
  • gn_NodeType
  • gn_ConnectorViewDefinition
  • gn_NodeViewDefinition
  • gn_systemDefaultCard

You may also need to package any associated Query Definitions (qry_QueryDefinition), Actions, and Methods, depending on your graph view configuration.