diff --git a/src/api/type.ts b/src/api/type.ts index 853affb..d29d993 100644 --- a/src/api/type.ts +++ b/src/api/type.ts @@ -54,6 +54,7 @@ export interface ChangeStatus { export interface FloorClass { user_id: string; + id: string; class_num: number; classroom_name: string; end_period: number; diff --git a/src/app/classChange/page.tsx b/src/app/classChange/page.tsx index b5b85e8..c851c09 100644 --- a/src/app/classChange/page.tsx +++ b/src/app/classChange/page.tsx @@ -143,7 +143,7 @@ const ClassChange = () => { handleAcceptListClick(item.user_id, item.username)} + onClick={() => handleAcceptListClick(item.id, item.username)} prevClass={item.move} nextClass={`${item.classroom_name}`} student={getStudentString(item)} diff --git a/src/app/outAccept/page.tsx b/src/app/outAccept/page.tsx index 56fb4ba..b1e7fbf 100644 --- a/src/app/outAccept/page.tsx +++ b/src/app/outAccept/page.tsx @@ -227,14 +227,12 @@ const OutAccept = () => { )) : applicationData?.map((item, index) => ( - handleAcceptListClick(item.user_id, item.username) - } + onClick={() => handleAcceptListClick(item.id, item.username)} reason={item.reason} /> ))}