diff --git a/src/Sylius/Bundle/AdminBundle/templates/admin_user/form/sections/personal_information/avatar.html.twig b/src/Sylius/Bundle/AdminBundle/templates/admin_user/form/sections/personal_information/avatar.html.twig index 894fb55474..5a2a705bd4 100644 --- a/src/Sylius/Bundle/AdminBundle/templates/admin_user/form/sections/personal_information/avatar.html.twig +++ b/src/Sylius/Bundle/AdminBundle/templates/admin_user/form/sections/personal_information/avatar.html.twig @@ -18,7 +18,7 @@ {{ form_widget(hookable_metadata.context.form.avatar) }} {% if admin_user.id is not null and admin_user.avatar is not null and admin_user.avatar.path is not empty %} diff --git a/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/payments/item/actions/refund.html.twig b/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/payments/item/actions/refund.html.twig index a98e462e69..fd0a1929fa 100644 --- a/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/payments/item/actions/refund.html.twig +++ b/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/payments/item/actions/refund.html.twig @@ -4,7 +4,9 @@ {% if sylius_sm_can(payment, constant('Sylius\\Component\\Payment\\PaymentTransitions::GRAPH'), constant('Sylius\\Component\\Payment\\PaymentTransitions::TRANSITION_REFUND')) %} - + {% if sylius_csrf_protection_enabled() %} + + {% endif %} diff --git a/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/shipments/item/actions/resend_confirmation.html.twig b/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/shipments/item/actions/resend_confirmation.html.twig index 901b4defd8..c17c2600f2 100644 --- a/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/shipments/item/actions/resend_confirmation.html.twig +++ b/src/Sylius/Bundle/AdminBundle/templates/order/show/content/sections/shipments/item/actions/resend_confirmation.html.twig @@ -1,7 +1,7 @@ {% set shipment = hookable_metadata.context.shipment %} {% if shipment.state == 'shipped' %} - {% set resend_path = path('sylius_admin_shipment_resend_confirmation_email', {'id': shipment.id, '_csrf_token': csrf_token(shipment.id)}) %} + {% set resend_path = path('sylius_admin_shipment_resend_confirmation_email', {'id': shipment.id, '_csrf_token': sylius_csrf_protection_enabled () ? csrf_token(shipment.id) : null}) %} {{ ux_icon('tabler:send') }} diff --git a/src/Sylius/Bundle/AdminBundle/templates/product_taxon/grid/action/update_positions.html.twig b/src/Sylius/Bundle/AdminBundle/templates/product_taxon/grid/action/update_positions.html.twig index 4ee799f439..ff1bffd48a 100644 --- a/src/Sylius/Bundle/AdminBundle/templates/product_taxon/grid/action/update_positions.html.twig +++ b/src/Sylius/Bundle/AdminBundle/templates/product_taxon/grid/action/update_positions.html.twig @@ -1,7 +1,7 @@ - + {% if sylius_csrf_protection_enabled() %} + + {% endif %}
{% endif %} diff --git a/src/Sylius/Bundle/ShopBundle/templates/shared/buttons.html.twig b/src/Sylius/Bundle/ShopBundle/templates/shared/buttons.html.twig index d067085c74..98acab090e 100644 --- a/src/Sylius/Bundle/ShopBundle/templates/shared/buttons.html.twig +++ b/src/Sylius/Bundle/ShopBundle/templates/shared/buttons.html.twig @@ -57,6 +57,8 @@ - + {% if sylius_csrf_protection_enabled() %} + + {% endif %} {% endmacro %} diff --git a/src/Sylius/Bundle/ShopBundle/templates/shared/components/delete_modal.html.twig b/src/Sylius/Bundle/ShopBundle/templates/shared/components/delete_modal.html.twig index 09ae7c55c3..572d95106b 100644 --- a/src/Sylius/Bundle/ShopBundle/templates/shared/components/delete_modal.html.twig +++ b/src/Sylius/Bundle/ShopBundle/templates/shared/components/delete_modal.html.twig @@ -13,7 +13,9 @@ {% block footer %}
- + {% if sylius_csrf_protection_enabled() %} + + {% endif %}