fixed searchParams
This commit is contained in:
@@ -5,10 +5,14 @@ import { GetStudent } from "@/app/lib/getStudent";
|
||||
|
||||
import "./addTime.css";
|
||||
|
||||
export default async function Page({ searchParams }: any) {
|
||||
export default async function Page(props:{
|
||||
searchParams?: Promise<{
|
||||
numAcount:string;
|
||||
}>
|
||||
}) {
|
||||
|
||||
const params =await searchParams;
|
||||
const numAccount = params.numAccount ? Number(params.numAccount) : null;
|
||||
const params =await props.searchParams;
|
||||
const numAccount = params?.numAcount ? parseInt(params.numAcount) : null;
|
||||
|
||||
let student: any = null;
|
||||
if (numAccount) {
|
||||
|
||||
@@ -8,8 +8,13 @@ import Information from "@/app/Components/Information/information";
|
||||
import SearchUser from "@/app/Components/SearchUser/searchUser";
|
||||
import { GetStudent } from "@/app/lib/getStudent";
|
||||
|
||||
export default function Page({ searchParams }: any) {
|
||||
const params = searchParams;
|
||||
export default async function Page(props:{
|
||||
searchParams?: Promise<{
|
||||
numAcount:string;
|
||||
}>
|
||||
}) {
|
||||
const params =await props.searchParams;
|
||||
const numAccount = params?.numAcount ? parseInt(params.numAcount) : null;
|
||||
|
||||
let student: any = null;
|
||||
let error: string | null = null;
|
||||
|
||||
@@ -8,9 +8,13 @@ import AlertBox from "@/app/Components/AlertBox/AlertBox";
|
||||
import { GetStudent } from "@/app/lib/getStudent";
|
||||
import "@/app/globals.css";
|
||||
|
||||
export default async function Page({ searchParams }: any) {
|
||||
const params = await searchParams;
|
||||
const numAccount = params.numAccount ? Number(params.numAccount) : null;
|
||||
export default async function Page(props: {
|
||||
searchParams?: Promise<{
|
||||
numAcount: string;
|
||||
}>;
|
||||
}) {
|
||||
const params = await props.searchParams;
|
||||
const numAccount = params?.numAcount ? parseInt(params.numAcount) : null;
|
||||
|
||||
let student: any = null;
|
||||
let error: string | null = null;
|
||||
@@ -46,7 +50,7 @@ export default async function Page({ searchParams }: any) {
|
||||
{
|
||||
key: "1",
|
||||
label: "Recibo",
|
||||
content: <Receipt numAccount={student.id_cuenta}/>,
|
||||
content: <Receipt numAccount={student.id_cuenta} />,
|
||||
},
|
||||
{
|
||||
key: "2",
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
import "./inscriptions.css";
|
||||
|
||||
import SearchUser from "@/app/Components/SearchUser/searchUser";
|
||||
import Information from "@/app/Components/Information/information";
|
||||
import StepNavigator from "@/app/Components/StepNavigator/StepNavigator";
|
||||
@@ -7,9 +5,16 @@ import Receipt from "@/app/Components/Receipt/Receipt";
|
||||
import Selection from "@/app/Components/Selection/Selection";
|
||||
import { GetStudent } from "@/app/lib/getStudent";
|
||||
|
||||
export default async function Page({ searchParams }: any) {
|
||||
const params = await searchParams;
|
||||
const numAccount = params.numAccount ? Number(params.numAccount) : null;
|
||||
import "./inscriptions.css";
|
||||
|
||||
export default async function Page(props:{
|
||||
searchParams?: Promise<{
|
||||
numAcount:string;
|
||||
}>
|
||||
}) {
|
||||
|
||||
const params =await props.searchParams;
|
||||
const numAccount = params?.numAcount ? parseInt(params.numAcount) : null;
|
||||
|
||||
let student: any = null;
|
||||
let error: string | null = null;
|
||||
@@ -49,3 +54,4 @@ export default async function Page({ searchParams }: any) {
|
||||
</section>
|
||||
);
|
||||
}
|
||||
//IO
|
||||
Reference in New Issue
Block a user