This topic contains 3 replies, has 2 voices, and was last updated by Stepan Yudin 7 years, 6 months ago.
- Topic
Good day everyone.
I need set default value for owner field in vendor datagrid (for example in sales-lead-grid)
The filter has following definition:123456789owner:type: choice-treelabel: oro.user.owner.labeldata_name: l.owneroptions:lazy: @oro_user.provider.filter.user_choice_tree->shouldBeLazydata: @?oro_user.provider.filter.user_choice_tree->getListI created datagrid listener and added ‘default’ block to datagrid definition:
12345678$filtersDefault = $config->offsetGetByPath('[filters][default]', array());$filtersDefault['owner'] = array('value' => $this->securityFacade->getLoggedUserId(),'type' => ChoiceTreeFilterType::TYPE_CONTAINS,);$config->offsetSetByPath('[filters][default]', $filtersDefault);But owner filter is still filled with ‘All’ value by default.
This approach works with simple text field, but not with this one.What am i doing wrong?
Docker environment for Symfony2/OroCRM/OroBAP development on Windows platform
https://github.com/stepansib/sf-oro-docker
The forum ‘OroPlatform – How do I? Questions’ is closed to new topics and replies.