fix forum

deskripsi:
- fix forumku , server action to API
This commit is contained in:
2025-02-17 17:49:31 +08:00
parent 882fb8922b
commit 28dd7cbda9
8 changed files with 316 additions and 62 deletions

View File

@@ -1,22 +1,14 @@
import { LayoutForum_Forumku } from "@/app_modules/forum";
import { user_getOneByUserId } from "@/app_modules/home/fun/get/get_one_user_by_id";
import React from "react";
export default async function Layout({
children,
params,
}: {
children: React.ReactNode;
params: { id: string };
}) {
const authorId = params.id;
const dataAuthor = await user_getOneByUserId(authorId);
return (
<>
<LayoutForum_Forumku username={dataAuthor?.username as any}>
{children}
</LayoutForum_Forumku>
<LayoutForum_Forumku>{children}</LayoutForum_Forumku>
</>
);
}

View File

@@ -34,8 +34,6 @@ export default async function Page({ params }: { params: { id: string } }) {
return (
<>
<Forum_Forumku
auhtorSelectedData={auhtorSelectedData as any}
dataPosting={dataPosting as any}
totalPosting={totalPosting}
userLoginId={userLoginId as any}
/>