_addons:
    resource: "addons.yml"
    prefix: /addons/

admin_module_cart:
    path: /cart/{moduleId}
    methods: [GET]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:getModuleCart
    requirements:
        moduleId: \d+

admin_module_catalog:
    path:     /catalog
    methods:  [GET]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:catalog
        _legacy_controller: AdminModulesCatalog
        _legacy_link: AdminModulesCatalog

admin_module_catalog_refresh:
    path:     /catalog/refresh/{category}/{keyword}
    methods:  [GET]
    defaults:
        category:
        keyword:
        _controller: PrestaShopBundle:Admin/Improve/Module:refreshCatalog
        _legacy_controller: AdminModulesCatalog
        _legacy_link: AdminModulesCatalog:refresh

admin_module_catalog_post:
    path:     /catalog/recommended
    methods:  [GET]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:getPreferredModules
        _legacy_controller: AdminModulesCatalog
        _legacy_link: AdminModulesCatalog:recommended

admin_module_manage:
    path:     /manage/{category}/{keyword}
    methods:  [GET]
    defaults:
        category:
        keyword:
        _controller: PrestaShopBundle:Admin/Improve/Module:manage
        _legacy_controller: AdminModulesManage
        _legacy_link:
            - AdminModulesManage
            - AdminModulesSf

admin_module_manage_action:
    path:     /manage/action/{action}/{module_name}
    methods:  [POST]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:module
    requirements:
        action: install|uninstall|enable|disable|enable_mobile|disable_mobile|reset|upgrade

admin_module_configure_action:
    path:     /manage/action/configure/{module_name}
    methods:  [GET, POST]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:configureModule
        _legacy_controller: AdminModules
# WARNING: This controller is not fully migrated yet, it is an overlay that redirects to the legacy controller,
# but here is the proper configuration when it will be really migrated
#        _legacy_link: AdminModules:configure
#        _legacy_parameters:
#            configure: module_name

admin_module_manage_action_bulk:
    path:     /manage/bulk/{action}
    methods:  [POST]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:module
    requirements:
        action: install|uninstall|configure|enable|disable|reset|upgrade

admin_module_manage_update_all:
    path:     /manage/update/all
    methods:  [POST]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Module:module

admin_module_import:
    path:     /import
    methods:  [POST]
    defaults:
        module_name:
        _controller: PrestaShopBundle:Admin/Improve/Module:importModule

admin_module_notification:
    path:     /alerts
    methods:  [GET]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Modules/Alerts:index
        _legacy_controller: AdminModulesNotifications
        _legacy_link: AdminModulesNotifications

admin_module_notification_count:
    path:     /alerts/count
    methods:  [GET]
    defaults:
        _controller: PrestaShopBundle:Admin\Improve\Modules\Alerts:notificationsCount
        _legacy_controller: AdminModulesNotifications
        _legacy_link: AdminModulesNotifications:count

admin_module_updates:
    path:     /updates
    methods:  [GET]
    defaults:
        _controller: PrestaShopBundle:Admin/Improve/Modules/Updates:index
        _legacy_controller: AdminModulesUpdates
        _legacy_link: AdminModulesUpdates

admin_module_addons_store:
    path:     /addons-store
    methods:  [GET]
    defaults:
        _controller: 'PrestaShopBundle:Admin\Improve\Modules\AddonsStore:index'
        _legacy_controller: AdminAddonsCatalog
        _legacy_link: AdminAddonsCatalog
