import { db } from "@/src/db";
import LocationSelector from "../../components/LocationSelector";
import LocationContextProvider from "@/components/locationContext";
import TotalSetter from "./TotalSetter";

export default async function Page() {
  const provinces = await db.query.province
    .findMany({ with: { zones: true } })
    .execute();
  return (
    <LocationContextProvider>
      <LocationSelector provinces={provinces} />
      <TotalSetter />
    </LocationContextProvider>
  );
}
