I need to set several predefined options for showing list of entities.
Sonata code:
class SubscriptionAdmin extends Admin {
protected function configureDatagridFilters(DatagridMapper $datagridMapper)
{
$datagridMapper
->add('created_at')
->add('status', 'doctrine_orm_choice', [], 'choice', ['choices' = ['active'=>'ecmo.enum.user.active', 'inactive'=>'ecmo.enum.user.active']
;
}
How i can set, that, by default, sonata show only active users, sorted by created_at
?