Add InPost Pay integration to admin templates
- Created a new template for the cart rule form with custom label, switch, and choice widgets. - Implemented the InPost Pay block in the order details template for displaying delivery method, APM, and VAT invoice request. - Added legacy support for the order details template to maintain compatibility with older PrestaShop versions.
This commit is contained in:
30
modules/inpostizi/config/services/admin/form.php
Normal file
30
modules/inpostizi/config/services/admin/form.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use izi\prestashop\Form\TypeExtension\DatePickerCompatibilityTypeExtension;
|
||||
use izi\prestashop\Form\TypeExtension\DateTimeImmutableTimeTypeExtension;
|
||||
use izi\prestashop\Form\TypeExtension\HelpTextExtension;
|
||||
use izi\prestashop\Form\TypeExtension\UnitTypeExtension;
|
||||
use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
|
||||
if (!defined('_PS_VERSION_') || Tools::version_compare(_PS_VERSION_, '8.0.0')) {
|
||||
return;
|
||||
}
|
||||
|
||||
assert(isset($container) && $container instanceof ContainerBuilder);
|
||||
|
||||
$classes = [
|
||||
DateTimeImmutableTimeTypeExtension::class,
|
||||
HelpTextExtension::class,
|
||||
UnitTypeExtension::class,
|
||||
];
|
||||
|
||||
$container->removeDefinition(DatePickerCompatibilityTypeExtension::class);
|
||||
|
||||
foreach ($classes as $class) {
|
||||
$container
|
||||
->getDefinition($class)
|
||||
->setTags([])
|
||||
->setDeprecated();
|
||||
}
|
||||
20
modules/inpostizi/config/services/admin/form.yml
Normal file
20
modules/inpostizi/config/services/admin/form.yml
Normal file
@@ -0,0 +1,20 @@
|
||||
services:
|
||||
izi\prestashop\Form\TypeExtension\DatePickerCompatibilityTypeExtension:
|
||||
class: izi\prestashop\Form\TypeExtension\DatePickerCompatibilityTypeExtension
|
||||
tags:
|
||||
- { name: form.type_extension, extended_type: PrestaShopBundle\Form\Admin\Type\DatePickerType }
|
||||
|
||||
izi\prestashop\Form\TypeExtension\DateTimeImmutableTimeTypeExtension:
|
||||
class: izi\prestashop\Form\TypeExtension\DateTimeImmutableTimeTypeExtension
|
||||
tags:
|
||||
- { name: form.type_extension, extended_type: Symfony\Component\Form\Extension\Core\Type\TimeType }
|
||||
|
||||
izi\prestashop\Form\TypeExtension\HelpTextExtension:
|
||||
class: izi\prestashop\Form\TypeExtension\HelpTextExtension
|
||||
tags:
|
||||
- { name: form.type_extension, extended_type: Symfony\Component\Form\Extension\Core\Type\FormType }
|
||||
|
||||
izi\prestashop\Form\TypeExtension\UnitTypeExtension:
|
||||
class: izi\prestashop\Form\TypeExtension\UnitTypeExtension
|
||||
tags:
|
||||
- { name: form.type_extension, extended_type: Symfony\Component\Form\Extension\Core\Type\IntegerType }
|
||||
1324
modules/inpostizi/config/services/common.yml
Normal file
1324
modules/inpostizi/config/services/common.yml
Normal file
File diff suppressed because it is too large
Load Diff
47
modules/inpostizi/config/services/common_admin.yml
Normal file
47
modules/inpostizi/config/services/common_admin.yml
Normal file
@@ -0,0 +1,47 @@
|
||||
# common BO configuration
|
||||
imports:
|
||||
- { resource: admin/form.yml }
|
||||
- { resource: admin/form.php, ignore_errors: true }
|
||||
|
||||
services:
|
||||
izi\prestashop\View\Asset\AssetManagerInterface: '@izi\prestashop\View\Asset\AdminAssetManager'
|
||||
izi\prestashop\View\Asset\AdminAssetManager:
|
||||
class: izi\prestashop\View\Asset\AdminAssetManager
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\View\Asset\Provider\Admin\CartRulesAssetsProvider:
|
||||
class: izi\prestashop\View\Asset\Provider\Admin\CartRulesAssetsProvider
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.admin_assets_provider }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@inpost.izi.request_stack'
|
||||
|
||||
izi\prestashop\Handler\Config\UpdateCartRuleOptionsHandlerInterface: '@izi\prestashop\Handler\Config\UpdateCartRuleOptionsHandler'
|
||||
izi\prestashop\Handler\Config\UpdateCartRuleOptionsHandler:
|
||||
class: izi\prestashop\Handler\Config\UpdateCartRuleOptionsHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\PromoCode\CartRuleOptionsRepositoryInterface'
|
||||
|
||||
izi\prestashop\Form\Type\CartRuleOptionsType:
|
||||
class: izi\prestashop\Form\Type\CartRuleOptionsType
|
||||
tags:
|
||||
- { name: form.type }
|
||||
arguments:
|
||||
- '@izi\prestashop\Translation\LegacyTranslator'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\Form\Type\ObjectModelType:
|
||||
class: izi\prestashop\Form\Type\ObjectModelType
|
||||
tags:
|
||||
- { name: form.type }
|
||||
arguments:
|
||||
- '@izi\prestashop\ObjectModel\ObjectManagerInterface'
|
||||
- '@inpost.izi.context'
|
||||
490
modules/inpostizi/config/services/common_front.yml
Normal file
490
modules/inpostizi/config/services/common_front.yml
Normal file
@@ -0,0 +1,490 @@
|
||||
# common FO configuration
|
||||
services:
|
||||
izi\prestashop\View\Asset\FrontAssetManager:
|
||||
class: izi\prestashop\View\Asset\FrontAssetManager
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\Hook\Front\ActionFrontControllerSetMedia:
|
||||
class: izi\prestashop\Hook\Front\ActionFrontControllerSetMedia
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\View\Asset\FrontAssetManager'
|
||||
- '@inpost.izi.security.authorization_checker'
|
||||
- !tagged inpost.izi.front_assets_provider
|
||||
- '@izi\prestashop\Configuration\ApiConfigurationInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayHeader:
|
||||
class: izi\prestashop\Hook\Front\DisplayHeader
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Configuration\GeneralConfigurationInterface'
|
||||
- '@izi\prestashop\Configuration\ApiConfigurationInterface'
|
||||
- '@inpost.izi.security.authorization_checker'
|
||||
- '@izi\prestashop\Analytics\Cookie\Executor\CookiePersisterExecutor'
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\Event\EventDispatcherInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\ActionGetPaymentOptions:
|
||||
class: izi\prestashop\Hook\Front\ActionGetPaymentOptions
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\Payment\PaymentCurrencyChecker'
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayIziThankYou:
|
||||
class: izi\prestashop\Hook\Front\DisplayIziThankYou
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayOrderConfirmation:
|
||||
class: izi\prestashop\Hook\Front\DisplayOrderConfirmation
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@inpost.izi.context'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayPaymentReturn:
|
||||
class: izi\prestashop\Hook\Front\DisplayPaymentReturn
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayProductActions:
|
||||
class: izi\prestashop\Hook\Front\DisplayProductActions
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayProductAdditionalInfo:
|
||||
class: izi\prestashop\Hook\Front\DisplayProductAdditionalInfo
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayShoppingCart:
|
||||
class: izi\prestashop\Hook\Front\DisplayShoppingCart
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayShoppingCartFooter:
|
||||
class: izi\prestashop\Hook\Front\DisplayShoppingCartFooter
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayExpressCheckout:
|
||||
class: izi\prestashop\Hook\Front\DisplayExpressCheckout
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayCheckoutSummaryTop:
|
||||
class: izi\prestashop\Hook\Front\DisplayCheckoutSummaryTop
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayCustomerAccountFormTop:
|
||||
class: izi\prestashop\Hook\Front\DisplayCustomerAccountFormTop
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayCustomerLoginFormAfter:
|
||||
class: izi\prestashop\Hook\Front\DisplayCustomerLoginFormAfter
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayIziCartPreviewButton:
|
||||
class: izi\prestashop\Hook\Front\DisplayIziCartPreviewButton
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Front\DisplayIziCheckoutButton:
|
||||
class: izi\prestashop\Hook\Front\DisplayIziCheckoutButton
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GuiConfiguration'
|
||||
- '@izi\prestashop\Configuration\GeneralConfiguration'
|
||||
- '@inpost.izi.module'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Controller\WidgetController:
|
||||
class: izi\prestashop\Controller\WidgetController
|
||||
public: true
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\CommandBus'
|
||||
- '@inpost.izi.widget_controller_locator'
|
||||
|
||||
izi\prestashop\Controller\Api\BasketController:
|
||||
class: izi\prestashop\Controller\Api\BasketController
|
||||
public: true
|
||||
arguments:
|
||||
- '@inpost.izi.serializer'
|
||||
- '@izi\prestashop\CommandBus'
|
||||
|
||||
izi\prestashop\Controller\Api\OrderController:
|
||||
class: izi\prestashop\Controller\Api\OrderController
|
||||
public: true
|
||||
arguments:
|
||||
- '@inpost.izi.serializer'
|
||||
- '@izi\prestashop\CommandBus'
|
||||
|
||||
izi\prestashop\Controller\Api\ProductController:
|
||||
class: izi\prestashop\Controller\Api\ProductController
|
||||
public: true
|
||||
arguments:
|
||||
- '@inpost.izi.serializer'
|
||||
- '@izi\prestashop\CommandBus'
|
||||
|
||||
izi\prestashop\Handler\GetBasketBindingKeyHandlerInterface: '@izi\prestashop\Handler\GetBasketBindingKeyHandler'
|
||||
izi\prestashop\Handler\GetBasketBindingKeyHandler:
|
||||
class: izi\prestashop\Handler\GetBasketBindingKeyHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\BasketApp\Basket\BasketsApiClientInterface'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\Handler\GetOrderConfirmationUrlHandlerInterface: '@izi\prestashop\Handler\GetOrderConfirmationUrlHandler'
|
||||
izi\prestashop\Handler\GetOrderConfirmationUrlHandler:
|
||||
class: izi\prestashop\Handler\GetOrderConfirmationUrlHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\Order\ContextCustomerUpdater'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\ConfirmBasketBindingHandlerInterface: '@izi\prestashop\MerchantApi\Handler\ConfirmBasketBindingHandler'
|
||||
izi\prestashop\MerchantApi\Handler\ConfirmBasketBindingHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\ConfirmBasketBindingHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\Builder\Basket\BasketBuilderFactory'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\DeleteBasketBindingHandlerInterface: '@izi\prestashop\MerchantApi\Handler\DeleteBasketBindingHandler'
|
||||
izi\prestashop\MerchantApi\Handler\DeleteBasketBindingHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\DeleteBasketBindingHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\GetBasketHandlerInterface: '@izi\prestashop\MerchantApi\Handler\GetBasketHandler'
|
||||
izi\prestashop\MerchantApi\Handler\GetBasketHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\GetBasketHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\Builder\Basket\BasketBuilderFactory'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\UpdateBasketHandlerInterface: '@izi\prestashop\MerchantApi\Handler\UpdateBasketHandler'
|
||||
izi\prestashop\MerchantApi\Handler\UpdateBasketHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\UpdateBasketHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\MerchantApi\Handler\Basket\BasketEventHandler'
|
||||
- '@izi\prestashop\Builder\Basket\BasketBuilderFactory'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\GetProductsHandlerInterface: '@izi\prestashop\MerchantApi\Handler\GetProductsHandler'
|
||||
izi\prestashop\MerchantApi\Handler\GetProductsHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\GetProductsHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\HotProduct\HotProductRepositoryInterface'
|
||||
- '@izi\prestashop\HotProduct\HotProductDataMapperInterface'
|
||||
- '@izi\prestashop\BasketApp\Product\ProductsApiClientInterface'
|
||||
- '@izi\prestashop\Cache\ConfigurationCache'
|
||||
- '@izi\prestashop\ObjectModel\Repository\ProductRepository'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\AddProductToBasketHandlerInterface: '@izi\prestashop\MerchantApi\Handler\AddProductToBasketHandler'
|
||||
izi\prestashop\MerchantApi\Handler\AddProductToBasketHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\AddProductToBasketHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\ContextManager'
|
||||
- '@izi\prestashop\CommandBusInterface'
|
||||
- '@izi\prestashop\Event\EventDispatcherInterface'
|
||||
- '@izi\prestashop\Builder\Basket\BasketBuilderFactory'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\CreateOrderHandlerInterface: '@izi\prestashop\MerchantApi\Handler\CreateOrderHandler'
|
||||
izi\prestashop\MerchantApi\Handler\CreateOrderHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\CreateOrderHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\CommandBusInterface'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\GetOrderHandlerInterface: '@izi\prestashop\MerchantApi\Handler\GetOrderHandler'
|
||||
izi\prestashop\MerchantApi\Handler\GetOrderHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\GetOrderHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.object_model.order_repository'
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
- '@izi\prestashop\Analytics\BasketAnalyticsRepositoryInterface'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\UpdateOrderHandlerInterface: '@izi\prestashop\MerchantApi\Handler\UpdateOrderHandler'
|
||||
izi\prestashop\MerchantApi\Handler\UpdateOrderHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\UpdateOrderHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.object_model.order_repository'
|
||||
- '@izi\prestashop\Configuration\OrdersConfiguration'
|
||||
- '@izi\prestashop\Builder\Order\OrderStatusDescriptionProvider'
|
||||
- '@inpost.izi.general_logger'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Order\UpdateCartMessageHandlerInterface: '@izi\prestashop\MerchantApi\Handler\Order\UpdateCartMessageHandler'
|
||||
izi\prestashop\MerchantApi\Handler\Order\UpdateCartMessageHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Order\UpdateCartMessageHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\ObjectModel\ObjectManagerInterface'
|
||||
- '@izi\prestashop\Configuration\OrdersConfiguration'
|
||||
- '@izi\prestashop\Order\Message\MessageFormatterInterface'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\CreateCartHandlerInterface: '@izi\prestashop\MerchantApi\Handler\Basket\CreateCartHandler'
|
||||
izi\prestashop\MerchantApi\Handler\Basket\CreateCartHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\CreateCartHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Configuration\PrestaShopConfiguration'
|
||||
- '@izi\prestashop\ObjectModel\ObjectManagerInterface'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\AddProductToCartHandlerInterface: '@izi\prestashop\MerchantApi\Handler\Basket\AddProductToCartHandler'
|
||||
izi\prestashop\MerchantApi\Handler\Basket\AddProductToCartHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\AddProductToCartHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\ObjectModel\Repository\ProductRepository'
|
||||
- '@izi\prestashop\Translation\LegacyTranslator'
|
||||
- '@inpost.izi.general_logger'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\IncrementCartQuantityHandlerInterface: '@izi\prestashop\MerchantApi\Handler\Basket\IncrementCartQuantityHandler'
|
||||
izi\prestashop\MerchantApi\Handler\Basket\IncrementCartQuantityHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\IncrementCartQuantityHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.command_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\ObjectModel\Repository\ProductRepository'
|
||||
- '@izi\prestashop\Translation\LegacyTranslator'
|
||||
- '@inpost.izi.general_logger'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\BasketEventHandlerInterface: '@izi\prestashop\MerchantApi\Handler\Basket\BasketEventHandler'
|
||||
izi\prestashop\MerchantApi\Handler\Basket\BasketEventHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\BasketEventHandler
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.basket_event_handler_locator'
|
||||
- '@izi\prestashop\ContextManager'
|
||||
- '@izi\prestashop\Event\EventDispatcherInterface'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\ProductsQuantityEventHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\ProductsQuantityEventHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.basket_event_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\ObjectModel\ObjectManager'
|
||||
- '@inpost.izi.general_logger'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\PromoCodesEventHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\PromoCodesEventHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.basket_event_handler }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\ObjectModel\ObjectManager'
|
||||
- '@inpost.izi.general_logger'
|
||||
|
||||
izi\prestashop\MerchantApi\Handler\Basket\RelatedProductsEventHandler:
|
||||
class: izi\prestashop\MerchantApi\Handler\Basket\RelatedProductsEventHandler
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.basket_event_handler }
|
||||
arguments:
|
||||
- '@izi\prestashop\CommandBusInterface'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\MerchantApi\Firewall\MerchantApiAuthenticator:
|
||||
class: izi\prestashop\MerchantApi\Firewall\MerchantApiAuthenticator
|
||||
public: true # todo: make private after refactoring the front controller
|
||||
arguments:
|
||||
- '@izi\prestashop\MerchantApi\Firewall\SigningKeysService'
|
||||
- '@inpost.izi.clock'
|
||||
|
||||
izi\prestashop\MerchantApi\Firewall\SigningKeysService:
|
||||
class: izi\prestashop\MerchantApi\Firewall\SigningKeysService
|
||||
public: false
|
||||
arguments:
|
||||
- '@izi\prestashop\BasketApp\Signature\SigningKeysApiClientInterface'
|
||||
- '@izi\prestashop\Cache\ConfigurationCache'
|
||||
|
||||
inpost.izi.security.access.decision_manager:
|
||||
class: Symfony\Component\Security\Core\Authorization\AccessDecisionManager
|
||||
public: false
|
||||
arguments:
|
||||
- !tagged inpost.izi.security_voter
|
||||
|
||||
inpost.izi.security.authorization_checker:
|
||||
class: izi\prestashop\Security\AuthorizationChecker
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.widget_controller_dependency, key: Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface }
|
||||
arguments:
|
||||
- '@inpost.izi.security.access.decision_manager'
|
||||
|
||||
izi\prestashop\Security\Voter\BindingWidgetVoter:
|
||||
class: izi\prestashop\Security\Voter\BindingWidgetVoter
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.security_voter }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GeneralConfigurationInterface'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\View\Asset\Provider\Front\CommonAssetsProvider:
|
||||
class: izi\prestashop\View\Asset\Provider\Front\CommonAssetsProvider
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.front_assets_provider }
|
||||
arguments:
|
||||
- '@inpost.izi.module'
|
||||
- '@inpost.izi.context'
|
||||
- '@inpost.izi.environment'
|
||||
|
||||
izi\prestashop\View\Asset\Provider\Front\ProductPageAssetsProvider:
|
||||
class: izi\prestashop\View\Asset\Provider\Front\ProductPageAssetsProvider
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.front_assets_provider }
|
||||
arguments:
|
||||
- '@izi\prestashop\Configuration\GeneralConfigurationInterface'
|
||||
- '@inpost.izi.context'
|
||||
|
||||
izi\prestashop\View\Asset\Provider\Front\WidgetConfigurationProvider:
|
||||
class: izi\prestashop\View\Asset\Provider\Front\WidgetConfigurationProvider
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.front_assets_provider }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Configuration\ApiConfigurationInterface'
|
||||
- '@izi\prestashop\Configuration\GeneralConfigurationInterface'
|
||||
- '@izi\prestashop\Repository\BasketSessionRepository'
|
||||
|
||||
izi\prestashop\Order\ContextCustomerUpdater:
|
||||
class: izi\prestashop\Order\ContextCustomerUpdater
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\ObjectModel\ObjectManagerInterface'
|
||||
131
modules/inpostizi/config/services/sf28.yml
Normal file
131
modules/inpostizi/config/services/sf28.yml
Normal file
@@ -0,0 +1,131 @@
|
||||
# PS < 1.7.4 configuration
|
||||
imports:
|
||||
- { resource: common.yml }
|
||||
- { resource: common_admin.yml }
|
||||
- { resource: common_front.yml }
|
||||
|
||||
parameters:
|
||||
inpost.izi.logs_dir: '%kernel.root_dir%/logs/inpost'
|
||||
|
||||
services:
|
||||
inpost.izi.event_dispatcher:
|
||||
class: Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher
|
||||
public: false
|
||||
arguments:
|
||||
- '@service_container'
|
||||
|
||||
izi\prestashop\CommandBus:
|
||||
class: izi\prestashop\CommandBus
|
||||
arguments:
|
||||
- '@inpost.izi.command_handler_locator'
|
||||
|
||||
inpost.izi.command_handler_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.command_handler, index_by: command_class, default_index_method: getHandledCommandClass }
|
||||
|
||||
izi\prestashop\Hook\HookExecutor:
|
||||
class: izi\prestashop\Hook\HookExecutor
|
||||
arguments:
|
||||
- '@inpost.izi.hook_locator'
|
||||
- '@inpost.izi.module'
|
||||
|
||||
inpost.izi.hook_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.hook, index_by: hook_name, default_index_method: getHookName }
|
||||
|
||||
inpost.izi.repository_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.model_repository, index_by: model_class }
|
||||
|
||||
inpost.izi.basket_event_handler_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.basket_event_handler, index_by: event_type, default_index_method: getHandledEventType }
|
||||
|
||||
izi\prestashop\Hook\Admin\ActionAdminCartRuleSaveAfter:
|
||||
class: izi\prestashop\Hook\Admin\ActionAdminCartRuleSaveAfter
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.form_factory'
|
||||
- '@izi\prestashop\CommandBusInterface'
|
||||
|
||||
izi\prestashop\Hook\Admin\ActionAdminControllerSetMedia:
|
||||
class: izi\prestashop\Hook\Admin\ActionAdminControllerSetMedia
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@izi\prestashop\View\Asset\AdminAssetManager'
|
||||
- !tagged inpost.izi.admin_assets_provider
|
||||
|
||||
izi\prestashop\Hook\Admin\DisplayBackOfficeHeader:
|
||||
class: izi\prestashop\Hook\Admin\DisplayBackOfficeHeader
|
||||
public: false
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
arguments:
|
||||
- '@inpost.izi.context'
|
||||
- '@izi\prestashop\Repository\CartRuleRepositoryInterface'
|
||||
- '@inpost.izi.form_factory'
|
||||
- '@izi\prestashop\View\Templating\RendererInterface'
|
||||
|
||||
izi\prestashop\Hook\Admin\DisplayAdminOrderLeft:
|
||||
class: izi\prestashop\Hook\Admin\DisplayAdminOrderLeft
|
||||
public: false
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.hook }
|
||||
|
||||
inpost.izi.constraint_validator_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: validator.constraint_validator }
|
||||
|
||||
inpost.izi.gui_configuration_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.gui_configuration_dependency, index_by: key }
|
||||
|
||||
izi\prestashop\Form\FormFactoryFactory:
|
||||
class: izi\prestashop\Form\FormFactoryFactory
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.validator'
|
||||
|
||||
inpost.izi.form_factory:
|
||||
class: Symfony\Component\Form\FormFactoryInterface
|
||||
factory: [ '@izi\prestashop\Form\FormFactoryFactory', create ]
|
||||
public: false
|
||||
arguments:
|
||||
- '@inpost.izi.form_type_locator'
|
||||
-
|
||||
Symfony\Component\Form\Extension\Core\Type\ChoiceType: ['@izi\prestashop\Form\TypeExtension\ChoicesAsValuesTypeExtension']
|
||||
Symfony\Component\Form\Extension\Core\Type\FormType: ['@izi\prestashop\Form\TypeExtension\HelpTextExtension']
|
||||
|
||||
inpost.izi.form_type_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: form.type }
|
||||
|
||||
izi\prestashop\Form\TypeExtension\ChoicesAsValuesTypeExtension:
|
||||
class: izi\prestashop\Form\TypeExtension\ChoicesAsValuesTypeExtension
|
||||
tags:
|
||||
- { name: form.type_extension, extended_type: Symfony\Component\Form\Extension\Core\Type\ChoiceType }
|
||||
|
||||
inpost.izi.widget_controller_locator:
|
||||
class: izi\prestashop\DependencyInjection\ServiceLocator
|
||||
autowire: true
|
||||
tags:
|
||||
- { name: inpost.izi.service_locator, tag: inpost.izi.widget_controller_dependency, index_by: key }
|
||||
72
modules/inpostizi/config/services/sf34.yml
Normal file
72
modules/inpostizi/config/services/sf34.yml
Normal file
@@ -0,0 +1,72 @@
|
||||
# PS >= 1.7.4 common FO/BO configuration
|
||||
imports:
|
||||
- { resource: common.yml }
|
||||
|
||||
services:
|
||||
_defaults:
|
||||
public: false
|
||||
|
||||
inpost.izi.repository_locator:
|
||||
class: Symfony\Component\DependencyInjection\ServiceLocator
|
||||
tags:
|
||||
- { name: container.service_locator }
|
||||
arguments:
|
||||
- Cart: '@inpost.izi.object_model.cart_repository'
|
||||
Country: '@inpost.izi.object_model.country_repository'
|
||||
Currency: '@izi\prestashop\ObjectModel\Repository\CurrencyRepository'
|
||||
Carrier: '@izi\prestashop\ObjectModel\Repository\CarrierRepository'
|
||||
CartRule: '@izi\prestashop\ObjectModel\Repository\CartRuleRepository'
|
||||
Combination: '@izi\prestashop\ObjectModel\Repository\CombinationRepository'
|
||||
Product: '@izi\prestashop\ObjectModel\Repository\ProductRepository'
|
||||
Configuration: '@izi\prestashop\ObjectModel\Repository\ConfigurationRepository'
|
||||
Hook: '@izi\prestashop\ObjectModel\Repository\HookRepository'
|
||||
Language: '@inpost.izi.object_model.language_repository'
|
||||
Order: '@inpost.izi.object_model.order_repository'
|
||||
OrderState: '@inpost.izi.object_model.order_state_repository'
|
||||
Shop: '@inpost.izi.object_model.shop_repository'
|
||||
InPostShipmentModel: '@izi\prestashop\ObjectModel\Repository\ShipmentRepository'
|
||||
|
||||
inpost.izi.event_dispatcher:
|
||||
class: Symfony\Component\EventDispatcher\EventDispatcherInterface
|
||||
factory: [ '@izi\prestashop\Event\EventDispatcherFactory', create ]
|
||||
|
||||
inpost.izi.event_subscriber_locator:
|
||||
class: Symfony\Component\DependencyInjection\ServiceLocator
|
||||
tags:
|
||||
- { name: container.service_locator }
|
||||
arguments:
|
||||
- izi\prestashop\EventListener\ShipmentListener: '@izi\prestashop\EventListener\ShipmentListener'
|
||||
izi\prestashop\EventListener\CartListener: '@izi\prestashop\EventListener\CartListener'
|
||||
izi\prestashop\EventListener\OrderListener: '@izi\prestashop\EventListener\OrderListener'
|
||||
izi\prestashop\Form\BasketAppClientProvider: '@?izi\prestashop\Form\BasketAppClientProvider'
|
||||
izi\prestashop\MerchantApi\EventListener\UpdateCartRulesListener: '@?izi\prestashop\MerchantApi\EventListener\UpdateCartRulesListener'
|
||||
izi\prestashop\HotProduct\EventListener\UpdateHotProductsListener: '@izi\prestashop\HotProduct\EventListener\UpdateHotProductsListener'
|
||||
izi\prestashop\EventListener\CreateShipmentListener: '@?izi\prestashop\EventListener\CreateShipmentListener'
|
||||
izi\prestashop\Mail\EventListener\ReplaceOrderNotificationRecipientListener: '@izi\prestashop\Mail\EventListener\ReplaceOrderNotificationRecipientListener'
|
||||
izi\prestashop\Analytics\EventListener\UpdateBasketAnalyticsListener: '@izi\prestashop\Analytics\EventListener\UpdateBasketAnalyticsListener'
|
||||
|
||||
izi\prestashop\Event\EventDispatcherFactory:
|
||||
class: izi\prestashop\Event\EventDispatcherFactory
|
||||
arguments:
|
||||
- '@inpost.izi.event_subscriber_locator'
|
||||
|
||||
inpost.izi.constraint_validator_locator:
|
||||
class: Symfony\Component\DependencyInjection\ServiceLocator
|
||||
tags: [ container.service_locator ]
|
||||
arguments:
|
||||
- izi\prestashop\Validator\Cart\BindableValidator: '@?izi\prestashop\Validator\Cart\BindableValidator'
|
||||
izi\prestashop\Validator\Cart\HasProductsValidator: '@?izi\prestashop\Validator\Cart\HasProductsValidator'
|
||||
izi\prestashop\Validator\Cart\PaymentInCurrencyAvailableValidator: '@?izi\prestashop\Validator\Cart\PaymentInCurrencyAvailableValidator'
|
||||
izi\prestashop\Validator\Product\NotInRestrictedCategoryValidator: '@izi\prestashop\Validator\Product\NotInRestrictedCategoryValidator'
|
||||
izi\prestashop\Validator\Product\NotFromRestrictedManufacturerValidator: '@izi\prestashop\Validator\Product\NotFromRestrictedManufacturerValidator'
|
||||
izi\prestashop\Validator\Product\NotWithRestrictedAttributesValidator: '@izi\prestashop\Validator\Product\NotWithRestrictedAttributesValidator'
|
||||
izi\prestashop\Validator\Product\NotWithRestrictedFeaturesValidator: '@izi\prestashop\Validator\Product\NotWithRestrictedFeaturesValidator'
|
||||
izi\prestashop\Validator\Product\UnrestrictedValidator: '@izi\prestashop\Validator\Product\UnrestrictedValidator'
|
||||
|
||||
inpost.izi.gui_configuration_locator:
|
||||
class: Symfony\Component\DependencyInjection\ServiceLocator
|
||||
tags: [ container.service_locator ]
|
||||
arguments:
|
||||
- validator: '@inpost.izi.validator'
|
||||
context: '@inpost.izi.shop_context'
|
||||
izi\prestashop\Repository\ProductRestrictionsRepositoryInterface: '@izi\prestashop\Repository\ProductRestrictionsRepositoryInterface'
|
||||
Reference in New Issue
Block a user