parameters:
    oro_dashboard.config_resolver.class:         Oro\Component\Config\Resolver\SystemAwareResolver
    oro_dashboard.manager.state.class:           Oro\Bundle\DashboardBundle\Model\StateManager
    oro_dashboard.manager.class:                 Oro\Bundle\DashboardBundle\Model\Manager
    oro_dashboard.widget_configs.class:          Oro\Bundle\DashboardBundle\Model\WidgetConfigs
    oro_dashboard.factory.class:                 Oro\Bundle\DashboardBundle\Model\Factory
    oro_dashboard.config_provider.class:         Oro\Bundle\DashboardBundle\Model\ConfigProvider
    oro_dashboard.dashboard_entity.class:        Oro\Bundle\DashboardBundle\Entity\Dashboard
    oro_dashboard.dashboard_widget_entity.class: Oro\Bundle\DashboardBundle\Entity\Widget
    oro_dashboard.navigation_listener.class:     Oro\Bundle\DashboardBundle\EventListener\NavigationListener
    oro_dashboard.form.type.edit.class:          Oro\Bundle\DashboardBundle\Form\Type\DashboardType
    oro_dashboard.form.type.select.class:        Oro\Bundle\DashboardBundle\Form\Type\DashboardSelectType

services:
    oro_dashboard.config_resolver:
        class: %oro_dashboard.config_resolver.class%
        arguments:
            - @service_container

    oro_dashboard.widget_configs:
        class: %oro_dashboard.widget_configs.class%
        arguments:
            - @oro_dashboard.config_provider
            - @oro_security.security_facade
            - @oro_dashboard.config_resolver

    oro_dashboard.manager:
        class: %oro_dashboard.manager.class%
        arguments:
            - @oro_dashboard.factory
            - @doctrine.orm.entity_manager
            - @oro_security.acl_helper
            - @security.context

    oro_dashboard.factory:
        class: %oro_dashboard.factory.class%
        arguments:
            - @oro_dashboard.config_provider
            - @oro_dashboard.manager.state

    oro_dashboard.manager.state:
        class: %oro_dashboard.manager.state.class%
        arguments:
            - @doctrine.orm.entity_manager
            - @oro_security.security_facade

    oro_dashboard.config_provider:
        class: %oro_dashboard.config_provider.class%
        arguments:
            - []

    oro_dashboard.navigation_listener:
        class: %oro_dashboard.navigation_listener.class%
        arguments:
            - @oro_security.security_facade
            - @oro_dashboard.manager
        tags:
            - { name: kernel.event_listener, event: oro_menu.configure.application_menu, method: onNavigationConfigure }

    oro_dashboard.form.type.edit:
        class: %oro_dashboard.form.type.edit.class%
        tags:
            - { name: form.type, alias: "oro_dashboard" }

    oro_dashboard.form.type.select:
        class: %oro_dashboard.form.type.select.class%
        arguments:
            - @oro_dashboard.manager
        tags:
            - { name: form.type, alias: "oro_dashboard_select" }
