umanit/sonata-admin-postgresql-search-bundle

Better search behaviour with Sonata admin and PostgreSQL

0.1 2018-06-15 12:23 UTC

This package is auto-updated.

Last update: 2020-07-12 12:30:27 UTC


README

This bundle overrides Sonata Admin search behaviour when using PostgreSQL. It makes all search case insensitive and unaccented.

Install

Register the bundle to your app/AppKernel.php

    // ...
    public function registerBundles()
    {
        $bundles = [
            // ...
            new Umanit\SonataAdminPostgreSQLSearchBundle\UmanitSonataAdminPostgreSQLSearchBundle(),
        ];
        // ...
    }

Create UNACCENT extension in your database.

CREATE EXTENSION IF NOT EXISTS UNACCENT;

That was it!