[ https://issues.oasis-open.org/browse/ODATA-960?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ralf Handl updated ODATA-960:
-----------------------------
Description:
We'd like to use a Singleton to control capabilities of an entity set, e.g. use a property of a singleton to tell whether the authenticated user is allowed to create new entities in a given entity set. This means we'd like to use a Path construct for the value of @Capabilities.InsertRestrictions/Insertable, e.g.
<Annotations Target="My.Container/SalesOrders">
<Annotation Term="Capabilities.InsertRestrictions">
<Record>
<PropertyValue Property="Insertable" Path="/My.Container/Me/Permissions/CanCreateOrders" />
</Record>
</Annotation>
</Annotations>
was:
We'd like to use a Singleton to control capabilities of an entity set, e.g. use a property of a singleton to tell whether the authenticated user is allowed to create new entities in a given entity set. This means we'd like to use a Path construct for the value of @Capabilities.InsertRestrictions/Insertable, e.g.
<Annotations Target="My.Container/SalesOrders">
<Annotation Term="Capabilities.InsertRestrictions">
<Record>
<PropertyValue Property="Insertable" Path="/Me/Permissions/CanCreateOrders" />
</Record>
</Annotation>
</Annotations>
Proposal:
Extend Path syntax to allow absolute paths that start with a top-level model element (schema child).
Natural syntax would be a path starting with a forward slash.
Note: current "relative" paths can already start with a type-cast segment which is a qualified type name, so the / prefix or something similar is needed to distinguish "absolute" paths.
was:
Extend Path syntax to allow absolute paths that are interpreted starting at the entity container.
Natural syntax would be a path starting with a forward slash.
> Absolute paths in annotations, e.g. capabilities depending on properties of a singleton
> ---------------------------------------------------------------------------------------
>
> Key: ODATA-960
> URL: https://issues.oasis-open.org/browse/ODATA-960
> Project: OASIS Open Data Protocol (OData) TC
> Issue Type: Improvement
> Components: Vocabularies
> Affects Versions: V4.0_ERRATA02
> Environment: Annotations
> Reporter: Ralf Handl
> Fix For: V4.01_WD01
>
>
> We'd like to use a Singleton to control capabilities of an entity set, e.g. use a property of a singleton to tell whether the authenticated user is allowed to create new entities in a given entity set. This means we'd like to use a Path construct for the value of @Capabilities.InsertRestrictions/Insertable, e.g.
> <Annotations Target="My.Container/SalesOrders">
> <Annotation Term="Capabilities.InsertRestrictions">
> <Record>
> <PropertyValue Property="Insertable" Path="/My.Container/Me/Permissions/CanCreateOrders" />
> </Record>
> </Annotation>
> </Annotations>
--
This message was sent by Atlassian JIRA
(v6.2.2#6258)