Skip to content

Commit 28a652e

Browse files
fix: searching by text
1 parent 5171797 commit 28a652e

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/utils/convert-filter.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,9 @@ const convertFilter = (filter) => {
2121
[Op.and]: [
2222
...(memo[Op.and] || []),
2323
where(
24-
fn('LOWER', col(`${property.sequelizePath.Model.name}.${property.name()}`)),
25-
Op.like,
26-
fn('LOWER', `%${escape(value)}%`),
27-
),
24+
fn('LOWER', col(`${property.sequelizePath.Model.name}.${property.name()}`)), {
25+
[Op.like]: fn('LOWER', `%${escape(value)}%`)
26+
}),
2827
],
2928
...memo,
3029
}

0 commit comments

Comments
 (0)