Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

custom filter " in like #8896

Closed
gebi84 opened this issue Nov 13, 2018 · 1 comment
Closed

custom filter " in like #8896

gebi84 opened this issue Nov 13, 2018 · 1 comment

Comments

@gebi84
Copy link

gebi84 commented Nov 13, 2018

i added a custom filter which works so far, but the select is building a query with like %"var"%

for what are this '"'? without this my code works

$this->values[] = '%"' . $session['filter'][$filter][$field] . '"%';

hery my issue:
i have a field date with values:
2016-10-11 13:29:29
2016-10-11 15:29:29

and now i want to filter by date "2016-10-11"

@fritzmg
Copy link
Contributor

fritzmg commented Nov 13, 2018

This is applied for fields where 'eval' => ['multiple' => true]. In that case, the database contains a serialized representation of the data. Thus Contao querys for %"…"%.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants