Section drag'n drop

Symfony 4 / Sonata: Create a nested CRUD interface (child 1->N) with drag'n drop ordering

Written by admin on 21/02/2020
Category:   PHP, symfony, Sonata
In short, we want to create a CRUD interface, 1N, with which, when we are editing an item, we add a panel to manage all the child items.Here we have a wtype table, with a wconf table that contains a series of records linked to a wtype item. Just like for the implementation example of sortable with drag'n'drop ( available here ) we are going to use the following components:pixassociates/sortable-behavior-bundle and stof/doctrine-extension...

Symfony 4 / Sonata: Manage the Order with Drag'n Drop

Written by on 20/02/2020
Category:   PHP, symfony, Sonata
You need to install pixassociates/sortable-behavior-bundle and stof/doctrine-extensions-bundle composer require stof/doctrine-extensions-bundle composer require pixassociates/sortable-behavior-bundle Add the configuration in pix_sortable.yamlBy adding the entity and the field in position_field (here wconf, and the position field) pix_sortable_behavior: db_driver: orm # mongodb default value : orm position_field: default: position #default value : position entities: ...