Skip to content

Commit 8835a11

Browse files
authoredNov 25, 2024··
Merge pull request #447 from GSadee/SYL-4156-refactor-parameters-names-in-1.x
Rename and deprecate parameters
2 parents 01cc445 + e5fabb9 commit 8835a11

File tree

4 files changed

+13
-3
lines changed

4 files changed

+13
-3
lines changed
 

‎UPGRADE-1.6.md

+7
Original file line numberDiff line numberDiff line change
@@ -97,3 +97,10 @@
9797
| `Sylius\RefundPlugin\StateResolver\RefundPaymentCompletedStateApplierInterface` | `sylius_refund.state_resolver.refund_payment_completed_applier` |
9898
| `Sylius\RefundPlugin\Validator\RefundAmountValidatorInterface` | `sylius_refund.validator.refund_amount` |
9999
| `Sylius\RefundPlugin\Validator\RefundUnitsCommandValidatorInterface` | `sylius_refund.validator.refund_units_command` |
100+
101+
1. The following old parameters have been deprecated and will be removed in RefundPlugin 2.0. Use the corresponding new parameters instead:
102+
103+
| Old parameter | New parameter |
104+
|------------------------------------|------------------------------------|
105+
| `default_logo_file` | `sylius_refund.default_logo_file` |
106+
| `sylius.refund.template.logo_file` | `sylius_refund.template.logo_file` |

‎src/Resources/config/app/config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ parameters:
1111
sylius_refund:
1212
pdf_generator:
1313
allowed_files:
14-
- '%env(default:default_logo_file:resolve:SYLIUS_REFUND_LOGO_FILE)%'
14+
- '%env(default:sylius_refund.default_logo_file:resolve:SYLIUS_REFUND_LOGO_FILE)%'
1515

1616
sylius_resource:
1717
resources:

‎src/Resources/config/services.xml

+4-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@
2222

2323
<parameters>
2424
<parameter key="default_logo_file">@SyliusRefundPlugin/Resources/assets/sylius-logo.png</parameter>
25-
<parameter key="sylius.refund.template.logo_file">%env(default:default_logo_file:resolve:SYLIUS_REFUND_LOGO_FILE)%</parameter>
25+
<parameter key="sylius.refund.template.logo_file">%env(default:sylius_refund.default_logo_file:resolve:SYLIUS_REFUND_LOGO_FILE)%</parameter>
26+
27+
<parameter key="sylius_refund.default_logo_file">%default_logo_file%</parameter>
28+
<parameter key="sylius_refund.template.logo_file">%sylius.refund.template.logo_file%</parameter>
2629
</parameters>
2730

2831
<services>

‎src/Resources/config/services/generators.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
<argument>null</argument>
5454
<argument type="service" id="file_locator" />
5555
<argument>@SyliusRefundPlugin/Download/creditMemo.html.twig</argument>
56-
<argument>%sylius.refund.template.logo_file%</argument>
56+
<argument>%sylius_refund.template.logo_file%</argument>
5757
<argument>null</argument>
5858
<argument type="service" id="sylius_refund.generator.twig_to_pdf" />
5959
<argument type="service" id="sylius_refund.generator.credit_memo_file_name" />

0 commit comments

Comments
 (0)
Please sign in to comment.