Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 
 
 
 

44 righe
2.4 KiB

  1. <?xml version="1.0"?>
  2. <!--
  3. /**
  4. * Copyright © Magento, Inc. All rights reserved.
  5. * See COPYING.txt for license details.
  6. */
  7. -->
  8. <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
  9. <type name="Magento\Framework\Module\Setup\Migration">
  10. <arguments>
  11. <argument name="compositeModules" xsi:type="array">
  12. <item name="giftmessage" xsi:type="string">Magento_GiftMessage</item>
  13. </argument>
  14. </arguments>
  15. </type>
  16. <preference for="Magento\GiftMessage\Api\CartRepositoryInterface" type="Magento\GiftMessage\Model\CartRepository"/>
  17. <preference for="Magento\GiftMessage\Api\ItemRepositoryInterface" type="Magento\GiftMessage\Model\ItemRepository"/>
  18. <preference for="Magento\GiftMessage\Api\GuestCartRepositoryInterface" type="Magento\GiftMessage\Model\GuestCartRepository"/>
  19. <preference for="Magento\GiftMessage\Api\GuestItemRepositoryInterface" type="Magento\GiftMessage\Model\GuestItemRepository"/>
  20. <preference for="Magento\GiftMessage\Api\OrderRepositoryInterface" type="Magento\GiftMessage\Model\OrderRepository"/>
  21. <preference for="Magento\GiftMessage\Api\OrderItemRepositoryInterface" type="Magento\GiftMessage\Model\OrderItemRepository"/>
  22. <preference for="Magento\GiftMessage\Api\Data\MessageInterface" type="Magento\GiftMessage\Model\Message"/>
  23. <type name="Magento\GiftMessage\Model\Plugin\QuoteItem" shared="false" />
  24. <type name="Magento\Quote\Model\Quote\Item\ToOrderItem">
  25. <plugin name="gift_message_quote_item_conversion" type="Magento\GiftMessage\Model\Plugin\QuoteItem"/>
  26. </type>
  27. <type name="Magento\Sales\Api\OrderRepositoryInterface">
  28. <plugin name="save_gift_message" type="Magento\GiftMessage\Model\Plugin\OrderSave"/>
  29. <plugin name="get_gift_message" type="Magento\GiftMessage\Model\Plugin\OrderGet"/>
  30. </type>
  31. <type name="Magento\Eav\Model\Config">
  32. <arguments>
  33. <argument name="attributesForPreload" xsi:type="array">
  34. <item name="catalog_product" xsi:type="array">
  35. <item name="gift_message_available" xsi:type="string">catalog_product</item>
  36. </item>
  37. </argument>
  38. </arguments>
  39. </type>
  40. <type name="Magento\Sales\Api\OrderItemRepositoryInterface">
  41. <plugin name="get_gift_message" type="Magento\GiftMessage\Model\Plugin\OrderItemGet"/>
  42. </type>
  43. </config>