Skip to content
This repository has been archived by the owner on Oct 13, 2023. It is now read-only.

Latest commit

 

History

History
34 lines (34 loc) · 1.49 KB

2021-08-05-enable-the-editing-of-promotions-in-existing-orders.md

File metadata and controls

34 lines (34 loc) · 1.49 KB
title issue
Enable the editing of promotions in existing orders
NEXT-13002

Core

  • Changed const \Shopware\Core\Checkout\Cart\Order\OrderConverter::ADMIN_EDIT_ORDER_PERMISSIONS to public
  • Added methods addPromotionLineItem and toggleAutomaticPromotion in \Shopware\Core\Checkout\Cart\Order\RecalculationService

API

  • Added new routes /api/_action/order/{orderId}/promotion-item and /api/_action/order/{orderId}/toggleAutomaticPromotions

Administration

  • Added blocks sw_order_detail_base_line_items_switch_promotions and sw_order_detail_base_line_items_voucher_field in src/module/sw-order/view/sw-order-detail-base/sw-order-detail-base.html.twig
  • Added following methods to component sw-order-detail-base
    • deleteAutomaticPromotion
    • toggleAutomaticPromotions
    • handlePromotionCodeTags
    • onSubmitCode
    • handlePromotionResponse
    • onRemoveExistingCode
    • getLineItemByPromotionCode
    • updatePromotionList
  • Added following computed properties to component sw-order-detail-base
    • orderLineItemRepository
    • disabledAutoPromotionVisibility
    • hasLineItem
    • currency
    • promotionCodeLineItems
    • hasAutomaticPromotions
    • promotionCodeTags
  • Added watcher order.lineItems to component sw-order-detail-base
  • Added mixin notification to component sw-order-detail-base
  • Added snippet sw-order.detailBase.textPromotionRemoved
  • Added methods addPromotionToOrder and toggleAutomaticPromotions to order.api.service