Hi NocoBase Team,
I’m experiencing an issue with the data scope feature in the add/edit form of the “Groups” collection. I need to filter the available “Teams” so that only those teams that are not yet assigned to any group are displayed. However, I’m unable to configure the data scope to achieve this.
Collection Structure:
- Collections:
- Competition
- Teams
- Groups
- Teams in the competition
- Team groups
- Relationships:
- Competition ↔ Teams: Many-to-Many relationship through the “Teams in the competition” collection.
Competition/source-key
= “Name En”Teams in the competition/Foreign-key
= “competitionIDname”Teams/source-key
= “Full Name (in English)”Teams in the competition/Foreign-key
= “TeamIDname”
- Groups ↔ Teams in the competition: Many-to-Many relationship through the “Team groups” collection.
Groups/source-key
= “ID”Team groups/Foreign-key
= “groupid”Teams in the competition/source-key
= “ID”Team groups/Foreign-key
= “teamid”
Issue:
In the “Groups” add/edit form, I want to configure the data scope to display only those “Teams” that have not yet been assigned to any group. However, I’m not sure how to set up the criteria in the data scope configuration to accomplish this.
Request:
Could you please guide me on how to set up the data scope for this scenario? Specifically, I need help filtering the “Teams” collection to exclude any teams already assigned to a group in the “Team groups” collection.
I have attached screenshots of the collections and the current data scope configuration for reference.
Thank you for your assistance!