简体   繁体   中英

Symfony Sonata Listmapper

I have an objet 'competition' MANYTOMANY but when i want to filter with listmapper. i have only two choice on advenced filter. "is equal to" and "is not equal to". I want to have a filter with "contains" !!! for the search - thanks


  /**
 * @param DatagridMapper $datagridMapper
 */
protected function configureDatagridFilters(DatagridMapper $datagridMapper)
{
    $datagridMapper
        ->add('name')
        ->add('country')
        ->add('contact')
        ->add('organisation')
        ->add('competition')
        ->add('descriptionlongnat', null, array('label' => 'Description national'))
        ->add('descriptionlongen', null, array('label' => 'Description english'))
        ->add('category')
        ->add('preservation', null, array('label' => 'Preservation method'))
        ->add('population', null, array('label' => 'Population target'))
        ->add('innovation')
        ->add('timeframe', null, array('label' => 'Comsumer timeframe'))
        ->add('component')
        ->add('created')
        ->add('updated')


    ;
}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM