Skip to content

Commit

Permalink
Fix ajax grid filtering - value not urlencoded
Browse files Browse the repository at this point in the history
When submitting an ajax filter with a value like "AT&T" the filter is interpreted wrong because it is not passed as encoded string to the request and gets cut off.
  • Loading branch information
marvinhinz authored Mar 14, 2018
1 parent 3722231 commit 2d68e2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Resources/views/blocks_js.jquery.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ function {{ grid.hash }}_submitForm(event, form)
if ($(this).attr('multiple') == 'multiple') {
for(var i= 0; i < value.length; i++)
{
data += '&' + name + '=' + value[i];
data += '&' + name + '=' + encodeURIComponent(value[i]);
}
} else {
data += '&' + name + '=' + value;
data += '&' + name + '=' + encodeURIComponent(value);
}
} else {
data += '&' + name + '=';
Expand Down

0 comments on commit 2d68e2d

Please sign in to comment.