Creating and Deleting relationships can be achieved in numerous ways to suit the task at hand.
Note: Adding relationships in view capabilities are detailed only for SharpCloud v9.7.0201 and later.
Adding Relationships in the View
Often the way items are related becomes apparent when looking at one or a series of views. SharpCloud allows relationships to be added directly from the context of the view, allowing the development of the view in real-time.
To add relationships in the view, follow these steps:
- Using the drop-down options on the relationship toggle (highlighted below), activate the “Create/Edit” option.
This will have a Relationship toolbar appear (as shown below), where there are various options which include:
Direction – Can easily choose the direction of the Relationship.
Colour – The colour of the relationship. These can be driven from Relationships Attributes, more information on those can be found HERE.
Thickness – The thickness of the relationship line, which is also driven from Relationship Attributes.
Note: For the Colour and Thickness options to appear, the relationship attribute must be set be displayed in the Relationships Tab on the View Setup.
- When hovering over any item, a circle will appear, which when dragged to another item, will form a relationship. This can be shown here:
Tip: By double clicking on the circle in the item you want to create the relationships from, the relationships can be drawn without having to grab the circle from the original item again.
This feature is also available to use when multiple items are selected, providing the capability to draw items from multiple items to other items really quickly.
Note: This method of creating relationships will work when more than 1 item is selected.
Deleting Relationships in the View
To delete relationships that have been created, simply navigate to relationships sub-tab in the right-hand side edit panel with the item selected and press the red “x” as shown below:
Adding Relationships using “Edit Relationships” dialog
Edit Relationships dialog allows for items to be searched by their name or category, allowing a more structured way of adding relationships. To access the Edit Relationships dialog, navigate to the relationships sub-tab in the Edit right-hand side tab as shown:
Upon selecting the “Edit Relationships” button, a new dialog will appear as shown:
To add relationships, simply select the “Add Relationship(s)” button in the bottom left of the dialog to generate a new dialog where items can be searched via category or name as shown:
Once the items have been selected to create the relationships to, select the Create button and those relationships will be created. This will close the dialog box and return back to the edit relationships dialog with the new relationships available to edit and enhance, like so:
Any relationship attributes will also be reflected in this dialog box to assign/edit values of on an individual relationship basis. Amending relationship attributes in context of a specific item selected is more manageable via the Edit Relationships than via the Data grid where all relationships will be displayed.
Deleting Relationships using “Edit Relationships” dialog
Deleting relationships is an easy process in the Edit Relationships dialog. Simply select the relationship (represented by a row) and press “Delete Relationships”, highlighted below:
Adding Relationships using the Data Grid
Once in the Data Grid (Selecting Data on the top toolbar), navigate to the Relationships tab as shown here:
By selecting New Relationship, a dialog box will appear:
From this dialog, items can be selected, and a comment added providing more information on the relationship.
Once “OK” is selected, the relationship will be created and displayed in the Data Grid.
Deleting Relationships using the Data Grid
When viewing the data grid and wanting to delete a relationship, simply select the relationship and press “Delete” as highlighted: