update build ok,
This commit is contained in:
@@ -48,7 +48,29 @@ export default function Page({ searchParams }: PageProps): React.JSX.Element {
|
|||||||
width: 'var(--Content-width)',
|
width: 'var(--Content-width)',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Page
|
<Stack spacing={4}>
|
||||||
|
<Stack direction={{ xs: 'column', sm: 'row' }} spacing={3} sx={{ alignItems: 'flex-start' }}>
|
||||||
|
<Box sx={{ flex: '1 1 auto' }}>
|
||||||
|
<Typography variant="h4">Lesson Categories</Typography>
|
||||||
|
</Box>
|
||||||
|
<Box sx={{ display: 'flex', justifyContent: 'flex-end' }}>
|
||||||
|
<Button startIcon={<PlusIcon />} variant="contained">
|
||||||
|
Add
|
||||||
|
</Button>
|
||||||
|
</Box>
|
||||||
|
</Stack>
|
||||||
|
<LessonCategoriesSelectionProvider lessonCategories={filteredLessonCategories}>
|
||||||
|
<Card>
|
||||||
|
<LessonCategoriesFilters filters={{ email, phone, status }} sortDir={sortDir} />
|
||||||
|
<Divider />
|
||||||
|
<Box sx={{ overflowX: 'auto' }}>
|
||||||
|
<LessonCategoriesTable rows={filteredLessonCategories} />
|
||||||
|
</Box>
|
||||||
|
<Divider />
|
||||||
|
<LessonCategoriesPagination count={filteredLessonCategories.length + 100} page={0} />
|
||||||
|
</Card>
|
||||||
|
</LessonCategoriesSelectionProvider>
|
||||||
|
</Stack>
|
||||||
</Box>
|
</Box>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@@ -54,9 +54,22 @@ export default function Page({ searchParams }: PageProps): React.JSX.Element {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const reloadRows = () => {
|
const reloadRows = () => {
|
||||||
console.log('reload rows');
|
// listLessonTypes()
|
||||||
|
// .then((lessonTypes: LessonType[]) => {
|
||||||
|
// setLessonTypesData(lessonTypes);
|
||||||
|
// })
|
||||||
|
// .catch((err) => {
|
||||||
|
// logger.error(err);
|
||||||
|
// toast(t('dashboard.lessonTypes.list.error'));
|
||||||
|
// });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
React.useEffect(() => {
|
||||||
|
reloadRows();
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
if (lessonTypesData.length < 1) return <FormLoading />;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Box
|
<Box
|
||||||
sx={{
|
sx={{
|
||||||
|
Reference in New Issue
Block a user