Fix search on email (#7094)

following email (text field type) -> emails (emails field type -
composite) migration!

closes https://github.com/twentyhq/twenty/issues/7080
This commit is contained in:
Marie
2024-09-17 14:57:34 +02:00
committed by GitHub
parent 3c306e9be8
commit fe4ca2133d

View File

@@ -174,7 +174,11 @@ export const CommandMenu = () => {
'firstName',
'lastName',
]),
{ email: { ilike: `%${commandMenuSearch}%` } },
...generateILikeFiltersForCompositeFields(
commandMenuSearch,
'emails',
['primaryEmail'],
),
{ phone: { ilike: `%${commandMenuSearch}%` } },
])
: undefined,