Repository navigation
relationships affect on ui
This section relates specifically to Object Properties and Collection Properties.
The UI changes its behaviour based on the RelationshipType and UiRenderOption configurations.
If you have an object (or collection property) that doesn't have a Relationship defined, the UI will:
- Render the property value on a separate tab
- Prevent the Add operation
- Prevent inline editing
public AssociatedObject NoRelationshipAndInlineSimple { get; set; } = new();
These properties are rendered as a single line using the object's ToString(). To see or edit the details, click the View button.
[Relationship(RelationshipType.Has)] //👈
[UI(UiRenderOption.InlineSimple)] //👈
public AssociatedObject AssociatedAndInlineSimple { get; set; } = new();
These properties are rendered in-line, but are not editable. Parent objects may not modify the values if they do not own them.
To edit the details, the value must be opened in a separate explorer.
[Relationship(RelationshipType.Has)] //👈
[UI(UiRenderOption.InlineExpanded)] //👈
public AssociatedObject AssociatedAndInlineExpanded { get; set; } = new();
These properties are rendered as a single line. To see or edit the details, click the View button.
[Relationship(RelationshipType.Owns)] //👈
[UI(UiRenderOption.InlineSimple)] //👈
public OwnedObject OwnedAndInlineSimple { get; set; } = new();
These properties are rendered in-line, and are editable. Because the parent object owns the property value, any modifications are safely within the bounds of the parent object.
[Relationship(RelationshipType.Owns)] //👈
[UI(UiRenderOption.InlineExpanded)] //👈
public OwnedObject OwnedAndInlineExpanded { get; set; } = new();
A question that may come up during your collaboration sessions is "Can we have in-line editing, to make the UI easier to use?".
The answer to this question is often "No." You should carefully review the RelationshipTypes with your Domain Experts, to ensure they reflect the truth of the domain.
UI and UX concerns should be handled as a separate activity, outside of your model design sessions.
Copyright © 2022-2026 Envivo Software
-
Objects
-
Configuring your Model
-
Testing your model
-
Other features