feat: persist view filters and sorts on Update View button click (#1290)

* feat: add viewFilters table

Closes #1121

* feat: add Update View button + Create View dropdown

Closes #1124, #1289

* feat: add View Filter resolvers

* feat: persist view filters and sorts on Update View button click

Closes #1123

* refactor: code review

- Rename recoil selectors
- Rename filters `field` property to `key`
This commit is contained in:
Thaïs
2023-08-23 18:20:43 +02:00
committed by GitHub
parent 76246ec880
commit 74ab0142c7
54 changed files with 1331 additions and 277 deletions

View File

@ -14,25 +14,25 @@ import { Person } from '~/generated/graphql';
export const peopleFilters: FilterDefinitionByEntity<Person>[] = [
{
field: 'firstName',
key: 'firstName',
label: 'First name',
icon: <IconUser size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'text',
},
{
field: 'lastName',
key: 'lastName',
label: 'Last name',
icon: <IconUser size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'text',
},
{
field: 'email',
key: 'email',
label: 'Email',
icon: <IconMail size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'text',
},
{
field: 'companyId',
key: 'companyId',
label: 'Company',
icon: (
<IconBuildingSkyscraper size={icon.size.md} stroke={icon.stroke.sm} />
@ -43,19 +43,19 @@ export const peopleFilters: FilterDefinitionByEntity<Person>[] = [
),
},
{
field: 'phone',
key: 'phone',
label: 'Phone',
icon: <IconPhone size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'text',
},
{
field: 'createdAt',
key: 'createdAt',
label: 'Created at',
icon: <IconCalendarEvent size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'date',
},
{
field: 'city',
key: 'city',
label: 'City',
icon: <IconMap size={icon.size.md} stroke={icon.stroke.sm} />,
type: 'text',