|
|
@@ -1,10 +1,13 @@
|
|
|
import { NextResponse } from "next/server";
|
|
|
import { listDays } from "@/lib/storage";
|
|
|
|
|
|
-export async function GET(request, { params }) {
|
|
|
- console.log("[/api/branches/[branch]/[year]/[month]/days] params:", params);
|
|
|
-
|
|
|
- const { branch, year, month } = params || {};
|
|
|
+export async function GET(request, ctx) {
|
|
|
+ const { branch, year, month } = await ctx.params;
|
|
|
+ console.log("[/api/branches/[branch]/[year]/[month]/days] params:", {
|
|
|
+ branch,
|
|
|
+ year,
|
|
|
+ month,
|
|
|
+ });
|
|
|
|
|
|
if (!branch || !year || !month) {
|
|
|
return NextResponse.json(
|