From 1ea82d752a733c7fc55f58106caea1f259efacfc Mon Sep 17 00:00:00 2001 From: Mateusz Zalewski Date: Mon, 24 Jun 2024 14:50:02 +0200 Subject: [PATCH] Fix add labels --- src/Form/Extension/OrderTypeExtension.php | 1 + src/Form/Type/OrderItemType.php | 1 + src/Resources/translations/messages.en.yaml | 2 ++ src/Resources/views/admin/order/update/_order_items.html.twig | 2 +- 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Form/Extension/OrderTypeExtension.php b/src/Form/Extension/OrderTypeExtension.php index 8ead7da..5372f1c 100644 --- a/src/Form/Extension/OrderTypeExtension.php +++ b/src/Form/Extension/OrderTypeExtension.php @@ -31,6 +31,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void 'entry_options' => [ 'currency' => $order->getCurrencyCode(), ], + 'button_add_label' => 'setono_sylius_order_edit.ui.add_discount', ]); }); diff --git a/src/Form/Type/OrderItemType.php b/src/Form/Type/OrderItemType.php index 976580e..3684cab 100644 --- a/src/Form/Type/OrderItemType.php +++ b/src/Form/Type/OrderItemType.php @@ -60,6 +60,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void 'entry_options' => [ 'currency' => $order->getCurrencyCode(), ], + 'button_add_label' => 'setono_sylius_order_edit.ui.add_discount', ]); }); diff --git a/src/Resources/translations/messages.en.yaml b/src/Resources/translations/messages.en.yaml index 5849f3a..a113870 100644 --- a/src/Resources/translations/messages.en.yaml +++ b/src/Resources/translations/messages.en.yaml @@ -1,5 +1,7 @@ setono_sylius_order_edit: ui: + add_discount: Add discount + add_order_item: Add order item discounts: Discounts order_discounts: Order discounts order_items: Order items diff --git a/src/Resources/views/admin/order/update/_order_items.html.twig b/src/Resources/views/admin/order/update/_order_items.html.twig index 3a99a4a..cc0f457 100644 --- a/src/Resources/views/admin/order/update/_order_items.html.twig +++ b/src/Resources/views/admin/order/update/_order_items.html.twig @@ -49,7 +49,7 @@