In some cases, you want to make sure that user has a relation to every instance of another relation.
For example, Assume you have a recording of a meeting and an employee shall be able to view this resource, if he/she was a participant of the meeting or is the boss of all those employees.
type employee
relations
define boss: [employee]
type recording_of_meeting
relations
define participant_of_meeting: [employee]
define can_access: participant_of_meeting or boss from participant_of_meeting
It would be useful to be able to define the relation as:
type employee
relations
define boss: [employee]
type recording_of_meeting
relations
define participant_of_meeting: [employee]
define can_access: participant_of_meeting or boss from all participant_of_meeting
In that case we'll check if the employee is the boss of all participants.
https://github.com/orgs/openfga/discussions/400
openfga/openfga#2156
In some cases, you want to make sure that user has a relation to every instance of another relation.
For example, Assume you have a recording of a meeting and an employee shall be able to view this resource, if he/she was a participant of the meeting or is the boss of all those employees.
It would be useful to be able to define the relation as:
In that case we'll check if the employee is the boss of all participants.
https://github.com/orgs/openfga/discussions/400
openfga/openfga#2156