fix: project
Deskripsi: - menampilkan semua anggota kecuali supadmin pada tambah kegiatan dan tambah anggota di kegiatan NO Issues
This commit is contained in:
@@ -133,13 +133,13 @@ export async function GET(request: Request, context: { params: { id: string } })
|
||||
const member = await prisma.user.findMany({
|
||||
where: {
|
||||
idGroup: String(groupId),
|
||||
id: {
|
||||
not: String(userId)
|
||||
},
|
||||
OR: [
|
||||
{ idUserRole: 'coadmin', },
|
||||
{ idUserRole: 'user', }
|
||||
],
|
||||
// id: {
|
||||
// not: String(userId)
|
||||
// },
|
||||
// OR: [
|
||||
// { idUserRole: 'coadmin', },
|
||||
// { idUserRole: 'user', }
|
||||
// ],
|
||||
isActive: true,
|
||||
name: {
|
||||
contains: (name == undefined || name == "null") ? "" : name,
|
||||
@@ -149,6 +149,7 @@ export async function GET(request: Request, context: { params: { id: string } })
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
idUserRole: true,
|
||||
name: true,
|
||||
email: true,
|
||||
img: true,
|
||||
@@ -172,7 +173,8 @@ export async function GET(request: Request, context: { params: { id: string } })
|
||||
idUser: v.id,
|
||||
name: v.name,
|
||||
email: v.email,
|
||||
img: v.img
|
||||
img: v.img,
|
||||
idUserRole: v.idUserRole
|
||||
}))
|
||||
|
||||
const dataFix = {
|
||||
|
||||
Reference in New Issue
Block a user