Relation matrices
For what a relation matrix is and how it’s used in pricing, see Relation matrices in Platform.
View relation matrices
Permissions:
update_product
From the product overview in Control Center, select Relation matrices in the left sidebar. In this view, relation matrices are listed in a table containing the following information.
| Column | Description |
|---|---|
| ID | Relation matrix identifier |
| Type | Matrix type: Station-based fare matrix, Station-category-based fare matrix, or Zone-based fare matrix |
| Slug | Relation matrix slug |
| Current fare matrix? | Whether this is the current fare matrix |
| Complete? | Whether the matrix is complete or has missing values |
| Description | Relation matrix description |
Zone-based fare matrices are not required to reference all of the product’s zones.
Create a relation matrix
Permissions:
manage_relation_matrices
To create a relation matrix, select Create new and enter the following information.
- Type. Select Station-based fare matrix, Station-category-based fare matrix, or Zone-based fare matrix from the dropdown menu.
- Slug. Enter the slug of the relation matrix. In general, slugs serve as unique identifiers that are used to reliably identify resources. Slugs may only contain lowercase letters (a–z), numbers (0–9), underscores (_), and hyphens (-). Spaces, uppercase letters, and special characters are not allowed.
- Description (optional)
Select Save.
Open the detailed view of a relation matrix
Permissions:
update_productPopulating missing elements requires
manage_relation_matrices.
To open the detailed view of a relation matrix, select ⚙️ > Show in the dropdown menu. Alternatively, select its slug in the table.
If a relation matrix is missing elements, a validation warning appears at the top of the detailed view. This warning states This relation matrix is missing the following elements and lists all affected combinations. Selecting Create missing elements with empty values automatically populates the relation matrix with empty values.
The following tabs are shown in the detailed view.
Overview
Editing cell values requires
manage_relation_matrices.
This tab provides an overview of the relation matrix details and shows the matrix.
To edit the value of a cell of the relation matrix, select the cell, make the desired changes, and then select Save. Alternatively, select Delete Element to reset the cell with an empty value.
Inspect
This tab displays a technical summary of the attributes of the relation matrix.
Edit a relation matrix
Permissions:
manage_relation_matrices
To edit a relation matrix, select ⚙️ > Edit in the dropdown menu. Make the desired changes and then select Save.
Set a relation matrix as the current fare matrix
Permissions:
manage_relation_matrices
To set a relation matrix as the current fare matrix, select ⚙️ > Set as current in the dropdown menu. This changes the field Current fare matrix within the section Fare calculation adapters in the management settings of a product.
Duplicate a relation matrix
Permissions:
manage_relation_matrices
To duplicate a relation matrix, select ⚙️ > Duplicate in the dropdown menu. Enter the type, slug, and description and then select Save.
Delete a relation matrix
Permissions:
manage_relation_matrices
To delete a relation matrix, select ⚙️ > Delete in the dropdown menu and then OK.