Admin Collaboration Done
# feat - Detail Project - Report Project ## No Issuue
This commit is contained in:
27
src/app/dev/colab/detail/group/[id]/page.tsx
Normal file
27
src/app/dev/colab/detail/group/[id]/page.tsx
Normal file
@@ -0,0 +1,27 @@
|
||||
import adminColab_getOneRoomChatById from "@/app_modules/admin/colab/fun/get/get_one_room_chat_by_id";
|
||||
import { Colab_GroupChatView } from "@/app_modules/colab";
|
||||
import colab_getMessageByRoomId from "@/app_modules/colab/fun/get/room_chat/get_message_by_room_id";
|
||||
import { user_getOneUserId } from "@/app_modules/fun_global/get_user_token";
|
||||
import _ from "lodash";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
const roomId = params.id;
|
||||
const userLoginId = await user_getOneUserId();
|
||||
const dataRoom = (await adminColab_getOneRoomChatById({ roomId: roomId }))
|
||||
.data;
|
||||
const selectRoom = _.omit(dataRoom, [
|
||||
"ProjectCollaboration",
|
||||
"ProjectCollaboration_AnggotaRoomChat",
|
||||
]);
|
||||
let listMsg = await colab_getMessageByRoomId({roomId: roomId, page: 1});
|
||||
|
||||
return (
|
||||
<>
|
||||
<Colab_GroupChatView
|
||||
userLoginId={userLoginId}
|
||||
listMsg={listMsg}
|
||||
selectRoom={selectRoom as any}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import colab_getListAnggotaByRoomId from "@/app_modules/colab/fun/get/room_chat/
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
let roomId = params.id;
|
||||
const dataRoom = await colab_getListAnggotaByRoomId(roomId)
|
||||
const dataRoom = await colab_getListAnggotaByRoomId(roomId);
|
||||
|
||||
return (
|
||||
<>
|
||||
|
||||
13
src/app/dev/colab/detail/notifikasi/[id]/page.tsx
Normal file
13
src/app/dev/colab/detail/notifikasi/[id]/page.tsx
Normal file
@@ -0,0 +1,13 @@
|
||||
import { Colab_DetailNotifikasi } from "@/app_modules/colab";
|
||||
import colab_getOneNotifikasiById from "@/app_modules/colab/fun/get/get_one_notifikasi_by_id";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
let notifId = params.id;
|
||||
const data = await colab_getOneNotifikasiById({ notifId: notifId });
|
||||
|
||||
return (
|
||||
<>
|
||||
<Colab_DetailNotifikasi data={data as any} />
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
import { LayoutColab_Main } from "@/app_modules/colab";
|
||||
import colab_CekNotifikasi from "@/app_modules/colab/fun/get/cek_notifikasi";
|
||||
import React from "react";
|
||||
|
||||
export default async function Layout({
|
||||
@@ -6,9 +7,11 @@ export default async function Layout({
|
||||
}: {
|
||||
children: React.ReactNode;
|
||||
}) {
|
||||
const cekNotif = await colab_CekNotifikasi();
|
||||
|
||||
return (
|
||||
<>
|
||||
<LayoutColab_Main>{children}</LayoutColab_Main>
|
||||
<LayoutColab_Main cekNotif={cekNotif as any}>{children}</LayoutColab_Main>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,13 @@
|
||||
import { Colab_NotifikasiView } from "@/app_modules/colab";
|
||||
import colab_getListNotifikasiByUserId from "@/app_modules/colab/fun/get/get_list_notifikasi_by_user_id";
|
||||
|
||||
export default async function Page() {
|
||||
const listNotifikasi = await colab_getListNotifikasiByUserId();
|
||||
// console.log(listNotifikasi);
|
||||
|
||||
return (
|
||||
<>
|
||||
<Colab_NotifikasiView />
|
||||
<Colab_NotifikasiView listNotifikasi={listNotifikasi as any} />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user