Commit graph

29393 commits

Author SHA1 Message Date
Łukasz Chruściel
8c6ad41cb5
bug #15548 [FIX] Default variant (Prometee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                  |
| Bug fix?        | yes                                                       |
| New feature?    | yes                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | yes |
| Related tickets | fixes #15547                      |
| License         | MIT                                                          |

This PR fix an issue introduced by #15273.
Variants are by default ordered by position via a specific Doctrine resource configuration :
https://github.com/Sylius/Sylius/blob/1.12/src/Sylius/Bundle/ProductBundle/Resources/config/doctrine/model/Product.orm.xml#L37-L38
This behaviour has to be cloned to retrieve the right variant.

Commits
-------

8e1303e554 Add deprecation notice mention by @diimpp
b2a2b3ea17 mention about service new argument
a48a8c8c0b Add orderBy position and id to get the same sets used on ->getEnabledVariants()
3d72280fa9 Add Scenario to test default variant
6d097ba1c3 Using findBy to avoid PSALM error
10a5de68a2 Update src/Sylius/Component/Product/Resolver/DefaultProductVariantResolver.php

Co-authored-by: Victor Vasiloi <victor.vasiloi@gmail.com>
00297e1593 Fix Spec tests
2023-11-22 12:36:35 +01:00
Francis Hilaire
00297e1593
Fix Spec tests 2023-11-20 20:08:23 +01:00
Francis Hilaire
10a5de68a2
Update src/Sylius/Component/Product/Resolver/DefaultProductVariantResolver.php
Co-authored-by: Victor Vasiloi <victor.vasiloi@gmail.com>
2023-11-20 19:52:52 +01:00
Francis Hilaire
6d097ba1c3
Using findBy to avoid PSALM error 2023-11-20 19:35:31 +01:00
Francis Hilaire
3d72280fa9
Add Scenario to test default variant 2023-11-20 19:31:27 +01:00
Francis Hilaire
a48a8c8c0b
Add orderBy position and id to get the same sets used on ->getEnabledVariants() 2023-11-20 17:53:54 +01:00
Francis Hilaire
b2a2b3ea17
mention about service new argument 2023-11-20 17:44:38 +01:00
Francis Hilaire
8e1303e554
Add deprecation notice mention by @diimpp 2023-11-20 16:34:11 +01:00
Grzegorz Sadowski
665c21a869
Change application's version to v1.12.13-dev 2023-11-17 13:48:12 +01:00
Grzegorz Sadowski
e9c6c255d3
Generate changelog for v1.12.12 2023-11-17 13:47:41 +01:00
Grzegorz Sadowski
3321507cbb
Change application's version to v1.12.12 2023-11-17 13:47:40 +01:00
Grzegorz Sadowski
bde9a62040
bug #15176 Add if_array check in ProductAttributeValueNormalizer.php (sdrenth, GSadee)
This PR was merged into the 1.12 branch.

Discussion
----------

Adds if_array check to prevent in_array check on null.

**Issue**
We ran into an error when it tries to do an in_array check where $object->getValue returns null.

**How to reproduce**
* Have an attribute of type SELECT
* Have an attribute value which has json_value NULL
* When trying to normalize the entity it will throw an error because it tries to do an in_array check on null.




Commits
-------

4906accf82 Add if_array check in ProductAttributeValueNormalizer.php
f4fbbf89f5 [API] Improve normalizing value of select attribute
2023-11-17 12:34:09 +01:00
Grzegorz Sadowski
9519ded805
bug #15287 Make the User class compatible with Symfony 6 to use encoder_name (delyriand, GSadee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | fixes #15286                      |
| License         | MIT                                                          |

<!--
 - Bug fixes must be submitted against the 1.12 branch
 - Features and deprecations must be submitted against the 1.13 branch
 - Make sure that the correct base branch is set

 To be sure you are not breaking any Backward Compatibilities, check the documentation:
 https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html
-->


Commits
-------

06f4fec706 fix(user): make compatible sf6 sylius user to use encoder_name on login
7eba4d0bdd doc: adds note on the PasswordHasherAwareInterface in User class
0d116c6ace Move note about PasswordHasherAwareInterface to the newest patch in the UPGRADE file
2023-11-17 12:33:36 +01:00
Grzegorz Sadowski
0d116c6ace
Move note about PasswordHasherAwareInterface to the newest patch in the UPGRADE file 2023-11-17 12:00:50 +01:00
Maxime Leclercq
7eba4d0bdd
doc: adds note on the PasswordHasherAwareInterface in User class 2023-11-17 12:00:49 +01:00
Maxime Leclercq
06f4fec706
fix(user): make compatible sf6 sylius user to use encoder_name on login 2023-11-17 12:00:49 +01:00
Grzegorz Sadowski
f4fbbf89f5
[API] Improve normalizing value of select attribute 2023-11-17 12:00:13 +01:00
Sander Drenth
4906accf82
Add if_array check in ProductAttributeValueNormalizer.php
Adds if_array check to prevent in_array check on null
2023-11-17 12:00:13 +01:00
Grzegorz Sadowski
5532b8cffe
bug #15487 Update taxation.rst (zairigimad, GSadee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                   |
| Bug fix?        | no                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                      |
| Deprecations?   | no |
| Related tickets | fixes #X, partially #Y, mentioned in #Z                      |
| License         | MIT                                                          |

<!--
 - Bug fixes must be submitted against the 1.12 branch
 - Features and deprecations must be submitted against the 1.13 branch
 - Make sure that the correct base branch is set

 To be sure you are not breaking any Backward Compatibilities, check the documentation:
 https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html
-->


Commits
-------

c724593223 Update taxation.rst
568d8422bb [Documentation] Minor improvement for note about tax calculators
2023-11-17 11:14:10 +01:00
Grzegorz Sadowski
568d8422bb
[Documentation] Minor improvement for note about tax calculators 2023-11-17 10:48:45 +01:00
Grzegorz Sadowski
1d9293a0a7
bug #15513 Update BootstrapTheme install doc (Florian-Merle)
This PR was merged into the 1.12 branch.

Discussion
----------

I was trying to install the BootstrapTheme, but it wasn't working because the `legacy_mode` part was not documented. Hope it's helpful :)

Commits
-------

24148df10a Update bootstrap-theme.rst
6ba56f8bce Update bootstrap-theme.rst
2023-11-17 10:41:15 +01:00
Grzegorz Sadowski
a0b5291b78
bug #15515 Update catalog_promotions.rst, fix links to BatchedApplyCatalogPromotionsOnVariantsCommandDispatcher and ApplyCatalogPromotionsOnVariants (vldmr-k)
This PR was merged into the 1.12 branch.

Discussion
----------

Fix links to classes: 

src/Sylius/Bundle/CoreBundle/CatalogPromotion/Command/ApplyCatalogPromotionsOnVariants.php src/Sylius/Bundle/CoreBundle/CatalogPromotion/CommandDispatcher/BatchedApplyCatalogPromotionsOnVariantsCommandDispatcher.php

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12 or 1.13 <!-- see the comment below -->                  |
| Bug fix?        | no/yes                                                       |
| New feature?    | no/yes                                                       |
| BC breaks?      | no/yes                                                       |
| Deprecations?   | no/yes <!-- don't forget to update the UPGRADE-*.md file --> |
| Related tickets | fixes #X, partially #Y, mentioned in #Z                      |
| License         | MIT                                                          |

<!--
 - Bug fixes must be submitted against the 1.12 branch
 - Features and deprecations must be submitted against the 1.13 branch
 - Make sure that the correct base branch is set

 To be sure you are not breaking any Backward Compatibilities, check the documentation:
 https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html
-->


Commits
-------

e97c6bd7eb Update catalog_promotions.rst
2023-11-17 10:38:45 +01:00
Jacob Tobiasz
d81bb852ab
minor #15531 Add ignore-parse-errors to composer require checker (Wojdylak)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12
| Bug fix?        | yes
| New feature?    | no
| BC breaks?      | no
| Deprecations?   | no
| Related tickets | #15527
| License         | MIT

[link](https://github.com/Sylius/Sylius/pull/15527#discussion_r1392682435)

Commits
-------
  Add ignore parse errors to composer require checker
2023-11-14 18:06:01 +01:00
Wojdylak
303b43063d Add ignore parse errors to composer require checker 2023-11-14 16:09:33 +01:00
Grzegorz Sadowski
7c3b5ed7c4
bug #15527 Disable check for security vulnerabilites step (Wojdylak)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12
| Bug fix?        | yes
| New feature?    | no
| BC breaks?      | no
| Deprecations?   | no
| Related tickets | N/A
| License         | MIT


Commits
-------

eba08b9042 Disable check for security vulnerabilites step
5a1f03c171 Add a conflict for "doctrine/doctrine-bundle": "2.11.0"
2023-11-14 13:30:12 +01:00
Wojdylak
5a1f03c171 Add a conflict for "doctrine/doctrine-bundle": "2.11.0" 2023-11-14 11:09:13 +01:00
Wojdylak
eba08b9042 Disable check for security vulnerabilites step 2023-11-14 09:57:44 +01:00
Jan Góralski
8a5ccd9416
bugfix #15507 Fix cart styles after form submission (data-route="sylius_shop_cart_c… (dsbe-ak)
This PR was merged into the 1.12 branch.

Discussion
----------


| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | fixes #15505                      |
| License         | MIT                                                          |


Commits
-------
  Fix cart styles after form submission (data-route="sylius_shop_cart_checkout")
2023-11-10 15:39:05 +01:00
Vladimir
e97c6bd7eb
Update catalog_promotions.rst
Fix links to classes: 

src/Sylius/Bundle/CoreBundle/CatalogPromotion/Command/ApplyCatalogPromotionsOnVariants.php
src/Sylius/Bundle/CoreBundle/CatalogPromotion/CommandDispatcher/BatchedApplyCatalogPromotionsOnVariantsCommandDispatcher.php
2023-11-10 11:25:13 +02:00
Jacob Tobiasz
7983278a50
bugfix #15512 [Maintenance] Fix request parameters accessing (NoResponseMate)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12 |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | -                      |
| License         | MIT                                                          |

Commits
-------
  [Maintenance] Fix AdminFilterSubscriber failing when no _route attribute present
  [Maintenance] Fix other possibly invalid route attribute getting
2023-11-10 09:13:23 +01:00
Florian Merle
6ba56f8bce
Update bootstrap-theme.rst 2023-11-09 17:58:43 +01:00
Florian Merle
24148df10a
Update bootstrap-theme.rst 2023-11-09 17:52:05 +01:00
Jan Goralski
c23f93dd4a
[Maintenance] Fix other possibly invalid route attribute getting 2023-11-09 13:39:07 +01:00
Jan Goralski
77c5415ac9
[Maintenance] Fix AdminFilterSubscriber failing when no _route attribute present 2023-11-09 13:07:23 +01:00
Andreas Kremsler
b71e56c62e Fix cart styles after form submission (data-route="sylius_shop_cart_checkout") 2023-11-08 10:53:03 +01:00
Zairig Imad
c724593223
Update taxation.rst 2023-11-01 11:02:03 +01:00
Jan Góralski
573052777a
bugfix #15449 [Behat] Set a LocaleCode via the HTTP Accept-Language header (Rafikooo)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12 <!-- see the comment below -->                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                      |
| Deprecations?   | no <!-- don't forget to update the UPGRADE-*.md file --> |
| License         | MIT                                                          |

It seems that in our tests we had an outdated way of setting locale

Commits
-------
  [Behat] Set a LocaleCode via the HTTP Accept-Language header
2023-10-18 16:45:39 +02:00
Rafikooo
5f2a8ea61f
[Behat] Set a LocaleCode via the HTTP Accept-Language header 2023-10-18 12:46:45 +02:00
Mateusz Zalewski
c0ccc7fa15
refactor #15437 [CS][DX] Refactor (bot@sylius.org)
This PR was merged into the 1.12 branch.

Discussion
----------

This PR has been generated automatically.
For more details see [refactor.yaml](/Sylius/Sylius/blob/1.12/.github/workflows/refactor.yaml).

Commits
-------

cd84b01b83 [CS][DX] Refactor
2023-10-17 23:42:10 +02:00
Sylius Bot
cd84b01b83 [CS][DX] Refactor 2023-10-16 02:17:19 +00:00
Jibé Barth
66231b4ac2
[Checkout] Prevent extra fields when login in on addressing page 2023-10-14 13:28:41 +02:00
Grzegorz Sadowski
d9ebdb639e
bug #15430 [Fix] Early return in CartCollector on stateless requests (NoResponseMate)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12 |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | fixes #15388 |
| License         | MIT                                                          |

Commits
-------

54e7f87883 [Fix] Early return in CartCollector on stateless requests
2023-10-13 15:19:59 +02:00
Jan Goralski
54e7f87883
[Fix] Early return in CartCollector on stateless requests 2023-10-12 14:46:06 +02:00
Grzegorz Sadowski
1b74e09849
bug #15416 [FIX][EMAIL] Use raw filter to avoid html encoded chars (Prometee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                   |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | fixes #12670                      |
| License         | MIT                                                          |

Following what @NoResponseMate suggeste here : https://github.com/Sylius/Sylius/issues/12670#issuecomment-1195216609
This PR applies a `raw` filter to each subject block available in Sylius (CoreBundle).

We can also decode html entities right after the block is rendered, but I don't know if it will break something if someone is using an API to send the email instead of a classic SMTP.


Commits
-------

149da4e31b Use raw filter to avoid html encoded chars in the subject of the each emails
2023-10-12 14:09:41 +02:00
Grzegorz Sadowski
cdc594563e
bug #15389 [FIX] Restrict NonChannelLocaleListener to the routes having _locale attribut (Prometee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no |
| Related tickets | fixes #13198 and maybe #15282                      |
| License         | MIT                                                          |

Before this PR behaviour:
Given the `%locale%` parameter is set to `en` for example and the available channel locales are different from this locale. When I reach a Payum route like `payum_capture_do` or any other route not beginning with `/{_locale}` and being part of the `shop` firewall.
Then I'm redirected to the homepage.

This PR will avoid redirecting to the homepage if no attribut locale is found in the route.



Commits
-------

813d66c0da Restrict the listener to the routes having _locale attribut
2023-10-12 13:58:49 +02:00
Grzegorz Sadowski
718cbc6038
bug #15273 [Issue 15271] - Get product variant by id (ulinskas, GSadee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12 <!-- see the comment below -->                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                      |
| BC breaks?      | no                                                      |
| Deprecations?   | no<!-- don't forget to update the UPGRADE-*.md file --> |
| Related tickets | fixes #15271                       |
| License         | MIT                                                          |

<!--
 - Bug fixes must be submitted against the 1.12 branch
 - Features and deprecations must be submitted against the 1.13 branch
 - Make sure that the correct base branch is set

 To be sure you are not breaking any Backward Compatibilities, check the documentation:
 https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html
-->

These changes increase admin performance and optimise memory usage.


Commits
-------

19ab3b9cd2 get default variant by id
04712ad53b Update ProductContext
7e04b04cf4 added backwards compatability and deprecation message
844654dce4 fallback to getter if product doesn't have an id
85bd10e675 Remove deprecation from DefaultProductVariantResolver that should be added in 1.13
2023-10-12 13:46:56 +02:00
Francis Hilaire
149da4e31b
Use raw filter to avoid html encoded chars in the subject of the each emails 2023-10-06 17:02:41 +02:00
Francis Hilaire
813d66c0da
Restrict the listener to the routes having _locale attribut 2023-10-06 12:23:19 +02:00
Jacob Tobiasz
f7855dead3
minor #15402 Fix failing phpspec scenario on Symfony 6.3.5 and above (GSadee)
This PR was merged into the 1.12 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.12|
| Bug fix?        | yes                                                       |
| New feature?    | no                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no|
| Related tickets | #15395 and #15397|
| License         | MIT                                                          |

<!--
 - Bug fixes must be submitted against the 1.12 branch
 - Features and deprecations must be submitted against the 1.13 branch
 - Make sure that the correct base branch is set

 To be sure you are not breaking any Backward Compatibilities, check the documentation:
 https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html
-->


Commits
-------
  Fix failing phpspec scenario on Symfony 6.3.5 and above
2023-10-05 07:52:41 +02:00
Jacob Tobiasz
06c21f2f2f
Fix failing phpspec scenario on Symfony 6.3.5 and above 2023-10-05 07:01:55 +02:00