Hey all, I'm working with Amplify and need to set up ownership of records based on teams instead of Cognito groups. I currently have a User model with their Cognito sub stored and I have a Team model with a relationship to users. I see that I can create a relationship to groups (https://docs.amplify.aws/cli/graphql/authorization-rules/#user-group-based-data-access). I am also aware of the example where each record can store a string of owner IDs. However, this would get cumbersome to do this for each record created.
Is there a way to do this so that the owner of a record (say, todo for example) is a team ID and all users linked to that team can have access?