forked from fictadvisor/fictadvisor
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
enhancement fictadvisor#354: refactor admin panel
- refactor fetching data in all files - refactor pages inside app folder and renamed components - renamed files inside those folders - renamed folders and fixed bugs in students - rewrite disciplines - api fix - admin styles
- Loading branch information
Showing
449 changed files
with
3,358 additions
and
5,175 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import React from 'react'; | ||
|
||
import CommentsAdminPage from '@/components/pages/admin/admin-comments'; | ||
import SeacrhCommentsAdminPage from '@/components/pages/admin/admin-comments/search-comments/SeacrhCommentsAdminPage'; | ||
|
||
const Page = () => { | ||
return <CommentsAdminPage />; | ||
return <SeacrhCommentsAdminPage />; | ||
}; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
'use client'; | ||
import React from 'react'; | ||
|
||
import AdminDepartmentsCreatePage from '@/components/pages/admin/admin-departments/admin-departments-create-page/AdminDepartmentsCreatePage'; | ||
import CreateDepartmentsAdminPage from '@/components/pages/admin/admin-departments/create-departments/CreateDepartmentsAdminPage'; | ||
|
||
const Page = () => { | ||
return <AdminDepartmentsCreatePage />; | ||
return <CreateDepartmentsAdminPage />; | ||
}; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
'use client'; | ||
import React from 'react'; | ||
|
||
import AdminDepartmentSearchPage from '@/components/pages/admin/admin-departments/admin-departments-search-page/AdminDepartmentSearchPage'; | ||
import SearchDepartmentsAdminPage from '@/components/pages/admin/admin-departments/search-departments/SearchDepartmentsAdminPage'; | ||
|
||
const Page = () => { | ||
return <AdminDepartmentSearchPage />; | ||
return <SearchDepartmentsAdminPage />; | ||
}; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
'use client'; | ||
import React from 'react'; | ||
|
||
import DisciplinesAdminCreatePage from '@/components/pages/admin/disciplines-admin-page/pages/disciplines-create-page/DisciplinesAdminCreatePage'; | ||
import CreateDisciplinesAdminPage from '@/components/pages/admin/admin-disciplines/create-disciplines'; | ||
|
||
const AdminSubjectCreate = () => { | ||
return <DisciplinesAdminCreatePage />; | ||
return <CreateDisciplinesAdminPage />; | ||
}; | ||
|
||
export default AdminSubjectCreate; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
'use client'; | ||
import React from 'react'; | ||
|
||
import DisciplinesAdminPage from '@/components/pages/admin/disciplines-admin-page/DisciplinesAdminPage'; | ||
import SearchDisciplinesAdminPage from '@/components/pages/admin/admin-disciplines/search-disciplines'; | ||
|
||
const DisciplinesAdminSearch = () => { | ||
return <DisciplinesAdminPage />; | ||
return <SearchDisciplinesAdminPage />; | ||
}; | ||
|
||
export default DisciplinesAdminSearch; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
'use client'; | ||
import React from 'react'; | ||
import { Box, Typography } from '@mui/material'; | ||
|
||
import Button from '@/components/common/ui/button'; | ||
import { | ||
ButtonColor, | ||
ButtonSize, | ||
ButtonVariant, | ||
} from '@/components/common/ui/button-mui/types'; | ||
import getErrorMessage from '@/lib/utils/getErrorMessage'; | ||
|
||
export default function Error({ | ||
error, | ||
reset, | ||
}: { | ||
error: Error & { digest?: string }; | ||
reset: () => void; | ||
}) { | ||
console.log(error); | ||
return ( | ||
<Box | ||
sx={{ | ||
display: 'flex', | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
flexDirection: 'column', | ||
minHeight: '100vh', | ||
}} | ||
> | ||
<Typography | ||
variant="h4Medium" | ||
style={{ color: 'grey.100', marginBottom: '32px' }} | ||
> | ||
Sorry! {getErrorMessage(error)} | ||
</Typography> | ||
<Box sx={{ maxWidth: '200px' }}> | ||
<Button | ||
text="Спробувати знову" | ||
size={ButtonSize.MEDIUM} | ||
color={ButtonColor.PRIMARY} | ||
variant={ButtonVariant.FILLED} | ||
onClick={reset} | ||
/> | ||
</Box> | ||
</Box> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import React from 'react'; | ||
|
||
import GroupsAdminPage from '@/components/pages/admin/admin-groups/search-groups-admin-page/AdminGroupsPage'; | ||
import SearchGroupsAdminPage from '@/components/pages/admin/admin-groups/search-groups/SearchGroupsAdminPage'; | ||
|
||
export default async function GroupsAdmin() { | ||
return <GroupsAdminPage />; | ||
return <SearchGroupsAdminPage />; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import React from 'react'; | ||
|
||
import QuestionsCreatePage from '@/components/pages/admin/questions-admin-page/components/questions-create-page'; | ||
import CreateQuestionsAdminPage from '@/components/pages/admin/admin-questions/create-questions/CreateQuestionsAdminPage'; | ||
|
||
const Page = () => { | ||
return <QuestionsCreatePage />; | ||
return <CreateQuestionsAdminPage />; | ||
}; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import React from 'react'; | ||
|
||
import QuestionsAdminPage from '@/components/pages/admin/questions-admin-page/QueationsAdminPage'; | ||
import SearchQuestionsAdminPage from '@/components/pages/admin/admin-questions/search-questions'; | ||
|
||
const Page = () => { | ||
return <QuestionsAdminPage />; | ||
return <SearchQuestionsAdminPage />; | ||
}; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import React from 'react'; | ||
|
||
import AdminRolesCreate from '@/components/pages/admin/admin-roles/create-roles-page/AdminRolesCreate'; | ||
import CreateRolesAdminPage from '@/components/pages/admin/admin-roles/create-roles/CreateRolesAdminPage'; | ||
|
||
const Create = () => { | ||
return <AdminRolesCreate />; | ||
return <CreateRolesAdminPage />; | ||
}; | ||
|
||
export default Create; |
Oops, something went wrong.