diff --git a/app/(main)/courses/[id]/@reviews/page.tsx b/app/(main)/courses/[id]/@reviews/page.tsx index c12afe8..80ca138 100644 --- a/app/(main)/courses/[id]/@reviews/page.tsx +++ b/app/(main)/courses/[id]/@reviews/page.tsx @@ -14,7 +14,7 @@ const getKey = (pageIndex: number, previousPageData: CoursesIDReviewsResponse) => { if (previousPageData && previousPageData.page === previousPageData.pages) return null; - return `/api/core/courses/${id}/reviews?page=${pageIndex + 1}&${params}`; + return `/django/core/courses/${id}/reviews?page=${pageIndex + 1}&${params}`; }; const Skeleton = () => diff --git a/app/(main)/courses/[id]/@schedules/page.tsx b/app/(main)/courses/[id]/@schedules/page.tsx index 983af95..97d28ce 100644 --- a/app/(main)/courses/[id]/@schedules/page.tsx +++ b/app/(main)/courses/[id]/@schedules/page.tsx @@ -12,7 +12,7 @@ const getKey = (pageIndex: number, previousPageData: CoursesIDSchedulesResponse) => { if (previousPageData && previousPageData.page === previousPageData.pages) return null; - return `/api/core/courses/${id}/schedules?page=${pageIndex + 1}`; + return `/django/core/courses/${id}/schedules?page=${pageIndex + 1}`; }; export default function Page({ params }: { params: { id: string } }) { diff --git a/app/(main)/professors/[id]/@reviews/page.tsx b/app/(main)/professors/[id]/@reviews/page.tsx index dbbd353..97a3c01 100644 --- a/app/(main)/professors/[id]/@reviews/page.tsx +++ b/app/(main)/professors/[id]/@reviews/page.tsx @@ -15,7 +15,7 @@ const getKey = (pageIndex: number, previousPageData: ProfessorsIDReviewsResponse) => { if (previousPageData && previousPageData.page === previousPageData.pages) return null; - return `/api/core/professors/${id}/reviews?page=${pageIndex + 1}&${params}`; + return `/django/core/professors/${id}/reviews/?page=${pageIndex + 1}&${params}`; }; const Skeleton = () => diff --git a/app/(main)/professors/[id]/@schedules/page.tsx b/app/(main)/professors/[id]/@schedules/page.tsx index 5e75f71..f76c144 100644 --- a/app/(main)/professors/[id]/@schedules/page.tsx +++ b/app/(main)/professors/[id]/@schedules/page.tsx @@ -12,7 +12,7 @@ const getKey = (pageIndex: number, previousPageData: ProfessorsIDSchedulesResponse) => { if (previousPageData && previousPageData.page === previousPageData.pages) return null; - return `/api/core/professors/${id}/schedules?page=${pageIndex + 1}`; + return `/django/core/professors/${id}/schedules/?page=${pageIndex + 1}`; }; export default function Page({ params }: { params: { id: string } }) { diff --git a/components/molecules/client/auth-btn/component.tsx b/components/molecules/client/auth-btn/component.tsx index 42dd7bf..7300043 100644 --- a/components/molecules/client/auth-btn/component.tsx +++ b/components/molecules/client/auth-btn/component.tsx @@ -16,7 +16,7 @@ export const AuthBtn: React.FC = ({ ...props }) => { const session = useSession(); if (session) { return ( - + Sign out ); @@ -24,7 +24,7 @@ export const AuthBtn: React.FC = ({ ...props }) => { return ( diff --git a/components/molecules/client/nav-search-bar/component.tsx b/components/molecules/client/nav-search-bar/component.tsx index d7cc09f..201d86f 100644 --- a/components/molecules/client/nav-search-bar/component.tsx +++ b/components/molecules/client/nav-search-bar/component.tsx @@ -20,7 +20,7 @@ const useCoursesSearchResults = (currentQuery: string) => { apiQueryParams.set('query', currentQuery); apiQueryParams.set('limit', '3'); const { data, error, isLoading } = useSWR( - `/api/core/courses/search?${apiQueryParams.toString()}`, + `/django/core/courses/search?${apiQueryParams.toString()}`, ); return { data, error, isLoading }; }; @@ -31,7 +31,7 @@ const useProfessorsSearchResults = (currentQuery: string) => { apiQueryParams.set('limit', '3'); const { data, error, isLoading } = useSWR( - `/api/core/professors/search?${apiQueryParams.toString()}`, + `/django/core/professors/search?${apiQueryParams.toString()}`, ); return { data, error, isLoading }; }; @@ -41,7 +41,7 @@ const useSchedulesSearchResults = (currentQuery: string) => { apiQueryParams.set('query', currentQuery); apiQueryParams.set('limit', '3'); const { data, error, isLoading } = useSWR( - `/api/core/schedules/search?${apiQueryParams.toString()}`, + `/django/core/schedules/search?${apiQueryParams.toString()}`, ); return { data, error, isLoading }; }; diff --git a/next.config.mjs b/next.config.mjs index ae84123..9585156 100644 --- a/next.config.mjs +++ b/next.config.mjs @@ -4,8 +4,8 @@ const nextConfig = { async rewrites() { return [ { - source: '/api/:root*', - destination: `${process.env.BASE_API_URL || ''}/:root*`, + source: '/django/:root*', + destination: `${process.env.BASE_API_URL || ''}/:root*/`, }, ]; },