Skip to content

Commit

Permalink
allItems needs to be an boolean
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeroen van den Nieuwenhuisen committed Aug 4, 2020
1 parent d002ef5 commit 66ca282
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/Controller/CRUDController.php
Original file line number Diff line number Diff line change
Expand Up @@ -368,15 +368,12 @@ public function batchAction(Request $request)
if ($data = json_decode($request->get('data', ''), true)) {
$action = $data['action'];
$idx = $data['idx'];
$allElements = $data['all_elements'];
$allElements = (bool) $data['all_elements'];
$request->request->replace(array_merge($request->request->all(), $data));
} else {
$request->request->set('idx', $request->get('idx', []));
$request->request->set('all_elements', $request->get('all_elements', false));

$action = $request->get('action');
$idx = $request->get('idx');
$allElements = $request->get('all_elements');
$action = $request->request->getAlnum('action');
$idx = $request->request->get('idx', []);
$allElements = $request->request->getBoolean('all_elements');
$data = $request->request->all();

unset($data['_sonata_csrf_token']);
Expand Down

0 comments on commit 66ca282

Please sign in to comment.