Skip to content

Commit

Permalink
Merge pull request #41 from lanfisis/master
Browse files Browse the repository at this point in the history
Add missing channelPriceHistoryConfig field to management in channel form for Sylius 1.13
  • Loading branch information
lanfisis authored Nov 20, 2024
2 parents ef29784 + 05a3d9d commit 3fa81ec
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Form/Extension/ChannelTypeExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void
->remove('currencies')
->remove('defaultTaxZone')
->remove('taxCalculationStrategy')
->remove('channelPriceHistoryConfig')
->addEventSubscriber(new RemoveBaseCurrencySubscriber())
;
}
Expand Down
5 changes: 5 additions & 0 deletions src/Resources/views/Admin/Channel/_noCommerceForm.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -80,5 +80,10 @@
{# {{ form_row(form.skippingPaymentStepAllowed) }}#}
{{ form_row(form.accountVerificationRequired) }}
</div>
{# <div class="ui attached segment">#}
{# {{ form_row(form.channelPriceHistoryConfig.lowestPriceForDiscountedProductsVisible) }}#}
{# {{ form_row(form.channelPriceHistoryConfig.lowestPriceForDiscountedProductsCheckingPeriod) }}#}
{# {{ form_row(form.channelPriceHistoryConfig.taxonsExcludedFromShowingLowestPrice, {'remote_url': path('sylius_admin_ajax_taxon_by_name_phrase'), 'load_edit_url': path('sylius_admin_ajax_taxon_by_code')}) }}#}
{# </div>#}
</div>
</div>
7 changes: 7 additions & 0 deletions src/Resources/views/Admin/Channel/_standardForm.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -80,5 +80,12 @@
{{ form_row(form.skippingPaymentStepAllowed) }}
{{ form_row(form.accountVerificationRequired) }}
</div>
{% if form.channelPriceHistoryConfig is defined %}
<div class="ui attached segment">
{{ form_row(form.channelPriceHistoryConfig.lowestPriceForDiscountedProductsVisible) }}
{{ form_row(form.channelPriceHistoryConfig.lowestPriceForDiscountedProductsCheckingPeriod) }}
{{ form_row(form.channelPriceHistoryConfig.taxonsExcludedFromShowingLowestPrice, {'remote_url': path('sylius_admin_ajax_taxon_by_name_phrase'), 'load_edit_url': path('sylius_admin_ajax_taxon_by_code')}) }}
</div>
{% endif %}
</div>
</div>

0 comments on commit 3fa81ec

Please sign in to comment.