You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add @inherit service to get inherited behavior values (#1887)
* Add `@inherit` service to get inherited behavior values
* changelog
* Check view permission to prevent using this to read data that should be private
* Nest behaviors under inherit
* edit intro to docs
* Apply suggestions from code review
Co-authored-by: Steve Piercy <[email protected]>
Co-authored-by: Jens W. Klein <[email protected]>
---------
Co-authored-by: Steve Piercy <[email protected]>
Co-authored-by: Jens W. Klein <[email protected]>
For each behavior, the service will find the closest ancestor which provides that behavior.
32
+
The result includes `from` (the `@id` and `title` of the item from which values were inherited) and `data` (values for any fields that are part of the behavior).
Ancestor items for which the current user lacks the `View` permission will be skipped.
39
+
40
+
(inherit-behaviors-expansion-label)=
41
+
42
+
## Expansion
43
+
44
+
This endpoint can be used with the {doc}`../usage/expansion` mechanism which allows getting more information about a content item in one query, avoiding unnecessary requests.
45
+
46
+
You can make a `GET` request for a content item, and include parameters to request `inherit` expansion for specific behaviors:
0 commit comments