PHPackages                             pixassociates/sortable-behavior-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. pixassociates/sortable-behavior-bundle

ActiveSymfony-bundle[Admin Panels](/categories/admin)

pixassociates/sortable-behavior-bundle
======================================

Provides a way to sort your admin listing

v1.5(8y ago)471.5M—5.9%80[8 issues](https://github.com/pix-digital/pixSortableBehaviorBundle/issues)[4 PRs](https://github.com/pix-digital/pixSortableBehaviorBundle/pulls)5MITPHPPHP &gt;=5.3.0

Since Nov 6Pushed 4y ago3 watchersCompare

[ Source](https://github.com/pix-digital/pixSortableBehaviorBundle)[ Packagist](https://packagist.org/packages/pixassociates/sortable-behavior-bundle)[ Docs](https://github.com/pix-digital/pixSortableBehaviorBundle)[ RSS](/packages/pixassociates-sortable-behavior-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (3)Versions (12)Used By (5)

pixSortableBehaviorBundle
=========================

[](#pixsortablebehaviorbundle)

Offers a sortable feature for your Symfony2 admin listing

### SonataAdminBundle implementation

[](#sonataadminbundle-implementation)

The SonataAdminBundle provides a cookbook article here :

[https://github.com/sonata-project/SonataAdminBundle/blob/3.x/docs/cookbook/recipe\_sortable\_listing.rst](https://github.com/sonata-project/SonataAdminBundle/blob/3.x/docs/cookbook/recipe_sortable_listing.rst)

### Configuration

[](#configuration)

By default, this extension works with Doctrine ORM, but you can choose to use Doctrine MongoDB by defining the driver configuration :

```
# app/config/config.yml
pix_sortable_behavior:
    db_driver: mongodb # default value : orm
    position_field:
        default: sort #default value : position
        entities:
            AppBundle\Entity\Foobar: order
            AppBundle\Entity\Baz: rang
    sortable_groups:
        entities:
            AppBundle\Entity\Baz: [ group ]

```

#### Use a draggable list instead of up/down buttons

[](#use-a-draggable-list-instead-of-updown-buttons)

In order to use a draggable list instead of up/down buttons, change the template in the `move` action to `PixSortableBehaviorBundle:Default:_sort_drag_drop.html.twig`.

```
