Allow using Relationships in Rule Expressions
When setting up the rules for a collection, sometimes I want to configure a role so that it can only perform a given action if a related document in a different collection has a field with a certain value. To do this now, it requires creating a Realm Function that queries that other collection for the related document, then returning the document, and finally having the the rule expression call that function and evaluate the document's fields.
While this does work, I think this could be made even easier by extending Relationships to be used in Rule Expressions. Currently, Relationships are something synced SDK data models and GraphQL operations can use to access documents directly referenced by the document being queried for. However, this functionality is not available for use in Rule Expressions.
Would it be possible to extend Relationships to allow them to be used in Rule Expressions as well?