# feat:
- Deskripsi: - Notifikasi collaboration ## Issue: Scroll dari chat akan di ubah dengan package yang mas malik buat
This commit is contained in:
@@ -13,11 +13,24 @@ export default async function colab_funCreatePartisipan(
|
||||
data: {
|
||||
projectCollaborationId: colabId,
|
||||
userId: userId,
|
||||
deskripsi_diri: deskripsi
|
||||
deskripsi_diri: deskripsi,
|
||||
},
|
||||
select: {
|
||||
ProjectCollaboration: {
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
userId: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
if (!create) return { status: 400, message: "Gagal menambahkan partisipan" };
|
||||
revalidatePath(RouterColab.main_detail + colabId);
|
||||
return { status: 201, message: "Berhasil menambahkan partisipan" };
|
||||
}
|
||||
return {
|
||||
data: create,
|
||||
status: 201,
|
||||
message: "Berhasil menambahkan partisipan",
|
||||
};
|
||||
}
|
||||
|
||||
@@ -32,6 +32,20 @@ export default async function colab_funCreateRoomChat(
|
||||
|
||||
if (!createAnggota)
|
||||
return { status: 400, message: "Gagal Menambah Anggota" };
|
||||
|
||||
const createdNotifikasi = await prisma.notifikasi.create({
|
||||
data: {
|
||||
userId: v,
|
||||
appId: createRoom.id,
|
||||
status: "Collaboration Group",
|
||||
title: "Grup Kolaborasi Baru",
|
||||
pesan: createRoom.name,
|
||||
kategoriApp: "COLLABORATION",
|
||||
userRoleId: "1",
|
||||
},
|
||||
});
|
||||
if (!createdNotifikasi)
|
||||
return { status: 400, message: "Gagal mengirim notifikasi" };
|
||||
}
|
||||
|
||||
const createForAuthor =
|
||||
|
||||
Reference in New Issue
Block a user