Skip to content

Commit

Permalink
refactor #308 Logo as parameter (Mateuszry)
Browse files Browse the repository at this point in the history
This PR was merged into the 1.0-dev branch.

Discussion
----------

Inspired by PR made on Invoicing plugin(Sylius/InvoicingPlugin#168) I decided to add logo as parameter to Refund plugin, because almost every user needs to replace the logo.

Commits
-------

2f35e27 Logo as parameter
  • Loading branch information
GSadee authored Jun 14, 2021
2 parents a38bf25 + 2f35e27 commit ec8e508
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions src/Resources/config/services.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@
<import resource="services/**/*.xml" />
</imports>

<parameters>
<parameter key="default_logo_file">@SyliusRefundPlugin/Resources/assets/sylius-logo.png</parameter>
<parameter key="sylius.refund.template.logo_file">%env(default:default_logo_file:SYLIUS_REFUND_LOGO_FILE)%</parameter>
</parameters>

<services>
<defaults autowire="false" autoconfigure="false" public="true" />

Expand Down
2 changes: 1 addition & 1 deletion src/Resources/config/services/generators.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
<argument type="service" id="knp_snappy.pdf" />
<argument type="service" id="file_locator" />
<argument>@SyliusRefundPlugin/Download/creditMemo.html.twig</argument>
<argument>@SyliusRefundPlugin/Resources/assets/sylius-logo.png</argument>
<argument>%sylius.refund.template.logo_file%</argument>
</service>
<service id="Sylius\RefundPlugin\Generator\CreditMemoPdfFileGenerator" alias="Sylius\RefundPlugin\Generator\CreditMemoPdfFileGeneratorInterface">
<deprecated>The "%alias_id%" service alias is deprecated and will be removed in RefundPlugin 1.0, use Sylius\RefundPlugin\Generator\CreditMemoPdfFileGeneratorInterface instead.</deprecated>
Expand Down

0 comments on commit ec8e508

Please sign in to comment.