28 lines
728 B
TypeScript
28 lines
728 B
TypeScript
import { DesignRegistPage } from "@/pages/design-cnstn";
|
|
import { parseTaskSeComCdFromApi } from "@/pages/design-cnstn/lib/design-cnstn-regist-schema";
|
|
|
|
interface PageProps {
|
|
searchParams: Promise<{
|
|
taskSeComCd?: string;
|
|
admdstCd?: string;
|
|
sido?: string;
|
|
gugun?: string;
|
|
}>;
|
|
}
|
|
|
|
export default async function Page({ searchParams }: PageProps) {
|
|
const params = await searchParams;
|
|
const taskSeComCd = parseTaskSeComCdFromApi(params.taskSeComCd);
|
|
|
|
return (
|
|
<DesignRegistPage
|
|
defaults={{
|
|
taskSeComCd: taskSeComCd.length ? taskSeComCd : undefined,
|
|
admdstCd: params.admdstCd,
|
|
sido: params.sido,
|
|
gugun: params.gugun,
|
|
}}
|
|
/>
|
|
);
|
|
}
|