parameters:
    orocrm_task.entity.class:                       OroCRM\Bundle\TaskBundle\Entity\Task
    orocrm_task.listener.datagrid.user_tasks.class: OroCRM\Bundle\TaskBundle\EventListener\Datagrid\UserTaskGridListener
    orocrm_task.listener.datagrid.activity.class:   OroCRM\Bundle\TaskBundle\EventListener\Datagrid\ActivityGridListener
    orocrm_task.calendar_provider.class:            OroCRM\Bundle\TaskBundle\Provider\TaskCalendarProvider
    orocrm_task.task.normalizer.class:              OroCRM\Bundle\TaskBundle\Provider\TaskCalendarNormalizer
    orocrm_task.placeholder.filter.class:           OroCRM\Bundle\TaskBundle\Placeholder\PlaceholderFilter
    orocrm_task.activity_list.provider.class:       OroCRM\Bundle\TaskBundle\Provider\TaskActivityListProvider

services:
    orocrm_task.listener.datagrid.user_tasks:
        class: %orocrm_task.listener.datagrid.user_tasks.class%
        arguments:
            - @oro_security.security_facade
        tags:
            - { name: kernel.event_listener, event: oro_datagrid.datagrid.build.before.user-tasks-grid, method: onBuildBefore }
            - { name: kernel.event_listener, event: oro_datagrid.datagrid.build.after.user-tasks-grid, method: onBuildAfter }

    orocrm_task.listener.datagrid.activity:
        class: %orocrm_task.listener.datagrid.activity.class%
        arguments:
            - @oro_activity.manager
            - @oro_entity.routing_helper
        tags:
            - { name: kernel.event_listener, event: oro_datagrid.datagrid.build.after.activity-tasks-grid, method: onBuildAfter }

    orocrm_task.widget_provider.actions.assign_task:
        parent: oro_ui.widget_provider.action_button.abstract
        arguments:
            - orocrm_assign_task_button
            - orocrm_assign_task_link
        tags:
            - { name: oro_ui.view_action_provider, group: activity }

    orocrm_task.calendar_provider:
        class: %orocrm_task.calendar_provider.class%
        arguments:
            - @oro_entity.doctrine_helper
            - @oro_security.acl_helper
            - @orocrm_task.task.normalizer
            - @translator
            - %orocrm_task.calendar_provider.my_tasks.enabled%
        tags:
            - { name: oro_calendar.calendar_provider, alias: tasks }

    orocrm_task.task.normalizer:
        class: %orocrm_task.task.normalizer.class%
        arguments:
            - @oro_reminder.entity.manager

    orocrm_task.placeholder.filter:
        class: %orocrm_task.placeholder.filter.class%
        arguments:
            - %orocrm_task.calendar_provider.my_tasks.enabled%

    orocrm_task.activity_list.provider:
        class: %orocrm_task.activity_list.provider.class%
        arguments:
           - @oro_entity.doctrine_helper
        tags:
           - {name: oro_activity_list.provider, priority: 20}
