Hey Joey, thanks for your answer. This example was...
# spicedb
n
Hey Joey, thanks for your answer. This example was simplified a bit. Here is a better description of how our product works. Would you (or someone else) be able to help us figure out how to achieve this? We have Files and Folders with
public_access
, and
team_access
fields. These are both nullable strings:
"edit"|"review"|"view"|"no_access"
. File and Folders can optionally have a parent folder When a public user attempts to view a File, it should check only the
public_access
field of that File, or the value of its parent in case the value is null (recursively). When a team member attempts to view a File, it should check both the
public_access
and the
team_access
fields of that File, or the value of its parent in case the value is null (recursively). Specific users can also be added to a File/Folder with a
user_access
value. When one of these users attempts to view a File, we should check the
user_access
value for that user, the
public_access
, and the
team_access
values for that File, and its parent in case they are null (recursively).