Add Role to TeamUser.

This commit is contained in:
Brian Cao 2022-11-28 13:08:48 -08:00
parent 502facd426
commit d5437c895e
4 changed files with 38 additions and 29 deletions

View file

@ -21,11 +21,10 @@ export async function getUserRoles(where: Prisma.UserRoleWhereInput): Promise<Us
});
}
export async function getUserRolesByUserId(userId: string, teamId?: string): Promise<UserRole[]> {
export async function getUserRolesByUserId(userId: string): Promise<UserRole[]> {
return prisma.client.userRole.findMany({
where: {
userId,
teamId,
},
});
}