imports:
    - { resource: tables.yml }

services:
    gfksx.thanksforposts.listener:
        class: gfksx\thanksforposts\event\listener
        arguments:
            - '@config'
            - '@dbal.conn'
            - '@auth'
            - '@template'
            - '@user'
            - '@cache.driver'
            - '@request'
            - '@controller.helper'
            - '@language'
            - '%core.root_path%'
            - '%core.php_ext%'
            - '@gfksx.thanksforposts.helper'
        tags:
            - { name: event.listener }
    gfksx.thanksforposts.helper:
        class: gfksx\thanksforposts\core\helper
        arguments:
            - '@config'
            - '@dbal.conn'
            - '@auth'
            - '@template'
            - '@user'
            - '@cache.driver'
            - '@request'
            - '@notification_manager'
            - '@controller.helper'
            - '@dispatcher'
            - '@language'
            - '%core.root_path%'
            - '%core.php_ext%'
            - '%tables.thanks%'
            - '%tables.users%'
            - '%tables.posts%'
            - '%tables.notifications%'
    gfksx.thanksforposts.controller.thankslist:
        class: gfksx\thanksforposts\controller\thankslist
        arguments:
            - '@config'
            - '@dbal.conn'
            - '@auth'
            - '@template'
            - '@user'
            - '@language'
            - '@cache.driver'
            - '@pagination'
            - '@profilefields.manager'
            - '@request'
            - '@controller.helper'
            - '%tables.posts%'
            - '%tables.thanks%'
            - '%tables.sessions%'
            - '%tables.users%'
            - '%core.root_path%'
            - '%core.php_ext%'
    gfksx.thanksforposts.controller.toplist:
        class: gfksx\thanksforposts\controller\toplist
        arguments:
            - '@config'
            - '@dbal.conn'
            - '@auth'
            - '@template'
            - '@user'
            - '@language'
            - '@cache.driver'
            - '%core.root_path%'
            - '%core.php_ext%'
            - '@pagination'
            - '@gfksx.thanksforposts.helper'
            - '@request'
            - '@controller.helper'
            - '%tables.forums%'
            - '%tables.thanks%'
            - '%tables.users%'
            - '%tables.posts%'
    gfksx.thanksforposts.notification.type.thanks:
        class: gfksx\thanksforposts\notification\thanks
        shared: false
        parent: notification.type.base
        calls:
            - [set_user_loader, ['@user_loader']]
            - [set_notifications_table, ['%tables.notifications%']]
        tags:
            - { name: notification.type }
    gfksx.thanksforposts.notification.type.thanks_remove:
        class: gfksx\thanksforposts\notification\thanks_remove
        shared: false
        parent: gfksx.thanksforposts.notification.type.thanks
        tags:
            - { name: notification.type }
