| | |
| | | import { styled } from '@mui/material/styles'; |
| | | import { DEFAULT_THEME_NAME } from '@/config/setting'; |
| | | import * as Common from '@/utils/common'; |
| | | import MailIcon from '@mui/icons-material/MailOutline' |
| | | import WcIcon from '@mui/icons-material/Wc'; |
| | | import BookmarkIcon from '@mui/icons-material/BookmarkBorder'; |
| | | import CategoryIcon from '@mui/icons-material/LocalOffer'; |
| | | import AccessTimeIcon from '@mui/icons-material/AccessTime'; |
| | | import { |
| | | endOfYesterday, |
| | | startOfWeek, |
| | |
| | | |
| | | const UserListAside = (props) => { |
| | | const theme = useTheme(); |
| | | const [themeName] = useStore('themeName', DEFAULT_THEME_NAME); |
| | | console.log() |
| | | console.log(endOfYesterday().toISOString()) |
| | | |
| | | const isSelected = (value, filters) => { |
| | | const categories = filters.categories || []; |
| | |
| | | > |
| | | <CardContent> |
| | | <SavedQueriesList icon={<BookmarkIcon />} /> |
| | | |
| | | <FilterLiveSearch source='condition' hiddenLabel /> |
| | | |
| | | <FilterList label="aa" icon={<MailIcon />}> |
| | | <FilterListItem label="Yes" value={{ status: '1' }} /> |
| | | <FilterListItem label="No" value={{ status: '0' }} /> |
| | | <FilterList |
| | | label="filters.lastCreated" |
| | | icon={<AccessTimeIcon />} |
| | | > |
| | | <FilterListItem |
| | | label="filters.today" |
| | | value={{ |
| | | timeStart: endOfYesterday().toISOString(), |
| | | timeEnd: undefined, |
| | | }} |
| | | /> |
| | | <FilterListItem |
| | | label="filters.thisWeek" |
| | | value={{ |
| | | timeStart: startOfWeek(new Date()).toISOString(), |
| | | timeEnd: undefined, |
| | | }} |
| | | /> |
| | | <FilterListItem |
| | | label="filters.lastWeek" |
| | | value={{ |
| | | timeStart: subWeeks(startOfWeek(new Date()), 1).toISOString(), |
| | | timeEnd: startOfWeek(new Date()).toISOString(), |
| | | }} |
| | | /> |
| | | <FilterListItem |
| | | label="filters.thisMonth" |
| | | value={{ |
| | | timeStart: startOfMonth(new Date()).toISOString(), |
| | | timeEnd: undefined, |
| | | }} |
| | | /> |
| | | <FilterListItem |
| | | label="filters.lastMonth" |
| | | value={{ |
| | | timeStart: subMonths(startOfMonth(new Date()), 1).toISOString(), |
| | | timeEnd: startOfMonth(new Date()).toISOString(), |
| | | }} |
| | | /> |
| | | <FilterListItem |
| | | label="filters.earlier" |
| | | value={{ |
| | | timeStart: undefined, |
| | | timeEnd: subMonths(startOfMonth(new Date()), 1).toISOString(), |
| | | }} |
| | | /> |
| | | </FilterList> |
| | | |
| | | <FilterList label="table.field.user.sex" icon={<WcIcon />}> |
| | | <FilterListItem label="Male" value={{ sex: '1' }} /> |
| | | <FilterListItem label="Female" value={{ sex: '2' }} /> |
| | | <FilterListItem label="They" value={{ sex: '0' }} /> |
| | | </FilterList> |
| | | |
| | | <FilterList label="Categories" icon={<CategoryIcon />}> |