SonataAdminBundle
                                
                                
                                
                                    SonataAdminBundle copied to clipboard
                            
                            
                            
                        Add search to list view
Feature Request
I'm planing to add a new feature which adds a new search field on each admin list. You can search for entities that may contain the searched value.

This can be done via a new SearchableAdminInterface:
interface SearchableAdminInterface
{
    /**
     * List of fields that are searchable
     * 
     * @return string[]
     */
    public function getSearchFields(): array;
}
class SomeAdmin extends AbstractAdmin implements SearchableAdminInterface
{
    public function getSearchFields(): array 
   {
       return ['address', 'name', 'description'];
   }
}
                                    
                                    
                                    
                                
I agree with the resulting feature, but I think we should consider the current implementation we have around the global_search option in the field description.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
HI @core23, I saw the bot added the stale label. Do you still work on this feature ?
I got this feature running on my local machine, but I need some time to integrate this into the existing sonata code.
Hi @core23, are you still able to provide a PR for this feature ?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.