feat: 동영상 게시글 수정

This commit is contained in:
2025-05-15 18:06:30 +09:00
parent 464e61f0c7
commit 846194e0ed
3 changed files with 15 additions and 12 deletions
+4 -7
View File
@@ -1,6 +1,6 @@
"use client";
import { useEffect, useRef, useState } from "react";
import { useRef, useState } from "react";
import { usePathname, useRouter } from "next/navigation";
import { useQuery } from "@tanstack/react-query";
import {
@@ -67,14 +67,15 @@ function PostPage({ bbsId }: { bbsId: string }) {
isFetched,
refetch,
} = useQuery({
queryKey: [ENDPOINT.BOARD_SERVICE.POSTS, bbsId],
queryKey: [ENDPOINT.BOARD_SERVICE.POSTS, bbsInfo?.bbsTypeCd],
queryFn: () =>
PostApi.getPostList(parseInt(bbsId), {
...postParams,
bbsTypeCd: bbsInfo?.bbsTypeCd,
page: pagination.pageIndex,
size: pagination.pageSize,
}),
enabled: false,
enabled: !!bbsInfo?.bbsTypeCd,
});
const isGridViewPage =
@@ -123,10 +124,6 @@ function PostPage({ bbsId }: { bbsId: string }) {
router.push(`${pathname}/${row.pstNo}`);
};
useEffect(() => {
refetch();
}, [pagination]);
return (
<div className="card card-border !mt-6">
<div className="card card-border">