Skip to content

Commit 33fdb6b

Browse files
committed
docs/[id]/edit に変更する
user_id を使って public.users から last_name を取得する仕様に変更したので e2e テストをテストユーザーでログインするもののみにする
1 parent b11d46e commit 33fdb6b

File tree

2 files changed

+4
-65
lines changed

2 files changed

+4
-65
lines changed

e2e/docs/[id]/page.e2e.test.ts

-61
This file was deleted.

src/app/docs/edit/page.tsx src/app/docs/[id]/edit/page.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { updateDoc } from "../_actions/updateDoc";
1+
import { updateDoc } from "../../_actions/updateDoc";
22
import { createClient } from "@/utils/supabase/server";
33
import SingleLayout from "@/components/layouts/SingleLayout";
44
import { Button } from "@/components/ui/button";
@@ -8,11 +8,11 @@ import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
88
import Link from "next/link";
99

1010
export default async function EditDoc({
11-
searchParams,
11+
params,
1212
}: {
13-
searchParams: Promise<{ id: string }>;
13+
params: Promise<{ id: string }>;
1414
}) {
15-
const id = (await searchParams).id;
15+
const { id } = await params;
1616
const supabase = await createClient();
1717
const { data } = await supabase
1818
.from("docs")

0 commit comments

Comments
 (0)