services:
    oro_note.form.type.note:
        class: Oro\Bundle\NoteBundle\Form\Type\NoteType
        tags:
            - { name: form.type, alias: oro_note }

    oro_note.form.type.note_api:
        class: Oro\Bundle\NoteBundle\Form\Type\NoteApiType
        arguments:
            - '@oro_entity_config.config_manager'
        tags:
            - { name: form.type, alias: oro_note_api }

    oro_note.form.note:
        class: Symfony\Component\Form\Form
        public: true
        factory: ['@form.factory', createNamed]
        arguments:
            - 'oro_note_form'
            - Oro\Bundle\NoteBundle\Form\Type\NoteType

    oro_note.form.note.api:
        class: Symfony\Component\Form\Form
        public: true
        factory: ['@form.factory', createNamed]
        arguments:
            - ''
            - Oro\Bundle\NoteBundle\Form\Type\NoteApiType

    Oro\Bundle\NoteBundle\Form\Handler\NoteHandler:
        alias: oro_note.form.handler.note

    oro_note.form.handler.note:
        class: Oro\Bundle\NoteBundle\Form\Handler\NoteHandler
        public: true
        arguments:
            - '@oro_note.form.note'
            - '@request_stack'
            - '@doctrine'
            - '@oro_activity.manager'

    oro_note.form.handler.note_api:
        class: Oro\Bundle\NoteBundle\Form\Handler\NoteApiHandler
        public: true
        arguments:
            - '@oro_note.form.note.api'
            - '@request_stack'
            - '@doctrine.orm.entity_manager'
            - '@oro_entity_config.config_manager'
