update build ok,

This commit is contained in:
louiscklaw
2025-04-16 03:00:54 +08:00
parent 607bd22808
commit 05a3beef9f
2 changed files with 37 additions and 2 deletions

View File

@@ -48,7 +48,29 @@ export default function Page({ searchParams }: PageProps): React.JSX.Element {
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>
);
}

View File

@@ -54,9 +54,22 @@ export default function Page({ searchParams }: PageProps): React.JSX.Element {
});
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 (
<Box
sx={{