ssossossossosso

Forums

Covering OroCRM topics, including community updates and company announcements.  Subscribe

Forums Forums OroCRM OroCRM – Programming Questions Sort and filter contacts by group

This topic contains 2 replies, has 1 voice, and was last updated by  klipach 2 years, 12 months ago.

  • Creator
    Topic
  • #22288

    klipach
    Participant

    In Oro 1.2 there was a Group filter and sorter in contact grid. In version 1.3 it is removed. Implementation from version 1.2 doesn’t work due to a bug. How can i add this filter/sorter?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Author
    Replies
  • #22289

    klipach
    Participant

    There is no answer for a long time… so i found some solution, it is not perfect but it works. You can add filter functionality by adding custom filter class. Here is an example:

    GroupFilter.php

    Register this filter in filters.yml

    don’t forget to load filters.yml in DependencyInjection/AcmeDemoExtension.php

    now you can use this filter in contact datagrid using eventListener like here https://github.com/orocrm/crm/blob/master/src/OroCRM/Bundle/CallBundle/EventListener/Datagrid/CallListener.php like

    or in datagrid.yml

    #22290

    klipach
    Participant

    Is there a better way to do such filtering?

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.