Closed ksn135 closed 8 years ago
Any chances to apply this fix on this weekend ?
@ksn135 is this fix working on your project?
It's allow me use array as value. Also you need to modify filter function:
protected function filterState($queryFilter, $value)
{
$queryFilter->addDefaultFilter('state', $value);
}
WBR, KSN.
On Mon, May 16, 2016 at 10:34 AM, Stéphane notifications@github.com wrote:
@ksn135 https://github.com/ksn135 is this fix working on your project?
— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/symfony2admingenerator/GeneratorBundle/pull/283#issuecomment-219366520
hi,
i had a similar problem: https://github.com/calvera/GeneratorBundle/blob/fixes/Resources/templates/CommonAdmin/ListAction/scopes.php.twig#L109
$filters['{{ filter }}'] = {%- if filterParams is not iterable -%}'{{ filterParams }}'{%- else -%}array({% for param in filterParams %}'{{ param }}'{% if not loop.last %},{% endif %}{% endfor %}){%- endif -%};
In my case I need to use several states (array) in filter to achieve required functionality (as it always works for me before in previous versions). Without this fix
cache:clear
throws exception>> Skip warmup An exception has been thrown during the rendering of a template ("Notice: Array to string conversion") in "../CommonAdmin/ListAction/scopes.php.twig".
Example: