Search on user list with mongo search query

This commit is contained in:
Carlos Mesquita
2024-09-09 01:38:11 +01:00
12 changed files with 158 additions and 131 deletions

View File

@@ -67,7 +67,7 @@ export async function getLinkedUsers(
const participants = uniq([
...adminGroups.flatMap((x) => x.participants),
...groups.flat().flatMap((x) => x.participants),
...(userType === "mastercorporate" ? groups.flat().flatMap((x) => x.participants) : []),
...(userType === "teacher" ? belongingGroups.flatMap((x) => x.participants) : []),
]);