Commit graph

1117 commits

Author SHA1 Message Date
Wojdylak
0097b04669
[ApiBundle] Remove nullable from AddItemToCart and ChangeItemQuantityInCart constructors 2024-01-23 12:38:57 +01:00
Kamil Grygierzec
0ea98a2bcb
Validate resending shipment confirmation email in correct state 2024-01-19 22:37:54 +01:00
Kamil Grygierzec
64f9a9b8e5
Apply changes from comments 2024-01-19 22:37:54 +01:00
Kamil Grygierzec
04ebfa0ac9
cover tests 2024-01-19 22:37:53 +01:00
Grzegorz Sadowski
499768193a
feature #15598 [API] Statistics (Rafikooo, TheMilek, NoResponseMate)
This PR was merged into the 1.13 branch.

Discussion
----------

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

This data response format is designed to facilitate chart generation. The following example is specifically for the annual sales summary with monthly intervals; other configurations will be added in future PRs.

This data format is intended for the Chart.js library, but it should also be easy to integrate with Google Charts.
It has built-in support for handling multiple datasets.

```json
{
	"salesChart": {
		"labels": [
			"2023-01-01",
			"2023-02-01",
			"2023-03-01",
			"2023-04-01",
			"2023-05-01",
			"2023-06-01",
			"2023-07-01",
			"2023-08-01",
			"2023-09-01",
			"2023-10-01",
			"2023-11-01",
			"2023-12-01"
		],
		"datasets": {
			"sales": [
				97043,
				17740,
				125045,
				54611,
				85021,
				78858,
				104452,
				45415,
				50234,
				29463,
				0,
				0
			] // If necessary, additional datasets could be included
		}
	},
	"businessActivitySummary": {
		"totalSales": 687882,
		"newOrdersCount": 14,
		"newCustomersCount": 21,
		"averageOrderValue": 49134
	},
	"intervalType": "month"
}
```


Commits
-------

da36901219 [Behat][API] Implement sales statistics scenarios
441aed53a3 [Behat] Launch the SharedStorageChannelContext class
a8b9c54e2c [PHPStan] Specify return types in the StatisticsDataProviderInterface service
37ad43e0de [ApiBundle] Implement Sales Statistics feature
3ab9268b0b [Swagger] Update Documentation for Sales Statistics API
d16a0e28e1 [CoreBundle] Introduce Sales Value Objects
71b836a6db [Core] Introduce Sales-Related Providers
bfe0777ddd [Core] Introduce SalesPeriodMapper service
e17e767f41 [ApiBundle] Refactor Sales Statistics implementation
7177037cdf [Unit] Update sales statistics response
7141ce072f [Behat] Remove the SharedStorageChannelContext class
a847aae5be [Unit] Add more tests for sales statistics
7439fb3940 [ApiBundle] Make accessing sales statistics stateless
5d55323cba [Swagger] Improve Documentation for Sales Statistics API
d369cfbbba [Refactor] Rename all SalesStatistics entries into Statistics
4f1d3ba857 [Core] Introduce the Chart concept and make adjustment to the related code
8669851c0e [Refactor] Change the GetStatistics query namespace
3f77c08104 [Statistics] Remove custom Period object in favor of native \DatePeriod
496a6ac474 [Unit] Add tests for validating sales statistics request parameters
bd77f55756 [Behat] Dashboard implementation improvements
33bf3648a5 [Behat] Remove unnecessary javascript tags
0c3bed5195 [Core] Add new method to OrderRepository
398961f31f [ApiBundle] Add validation for requesting statistics
6e71fe259f [Behat] Add API tags for statistics scenarios
2296ce7db9 [ApiBundle] Extract validation logic from GetStatisticsAction controller
fb21237891 Remove specs for unexisting classes and add existing ones
e3e9b33937 fix behat tests
fcf725812c Apply changes from comments and improve outdated StatisticsModifier
a0f2ecfc4b fix unit test
1199cef9dd Change new orders name to paid orders to not mix up names
1e196e2136 [Statistics] Refactor GetStatisticsAction
2109c1716b [DX] Update OrderRepository
2024-01-18 07:20:13 +01:00
Jan Góralski
a8e1e1af21
bugfix #15739 Fix ZoneRepository BC-Break (Rafikooo)
This PR was merged into the 1.13 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.13 <!-- see the comment below -->                  |
| Bug fix?        | yes                                                       |
| New feature?    | no                                                      |
| BC breaks?      | not anymore                                                      |
| Related tickets | https://github.com/Sylius/Sylius/pull/15275#discussion_r1341257295  |
| License         | MIT                                                          |


Commits
-------
  [Upgrade] Note ZoneRepository addition and ZoneMatcher constructor changes
  [Addressing] Support BC for ZoneMatcher
  [ECS] Apply ecs fixes
2024-01-17 17:42:26 +01:00
Rafikooo
9475f31766
[ECS] Apply ecs fixes 2024-01-17 17:03:42 +01:00
Kamil Grygierzec
1199cef9dd
Change new orders name to paid orders to not mix up names 2024-01-17 15:14:16 +01:00
Kamil Grygierzec
a0f2ecfc4b
fix unit test 2024-01-17 15:14:16 +01:00
Rafikooo
2296ce7db9
[ApiBundle] Extract validation logic from GetStatisticsAction controller 2024-01-17 15:14:16 +01:00
Rafikooo
bd77f55756
[Behat] Dashboard implementation improvements 2024-01-17 14:22:20 +01:00
Rafikooo
496a6ac474
[Unit] Add tests for validating sales statistics request parameters 2024-01-17 14:22:20 +01:00
Rafikooo
4f1d3ba857
[Core] Introduce the Chart concept and make adjustment to the related code 2024-01-17 14:22:20 +01:00
Rafikooo
d369cfbbba
[Refactor] Rename all SalesStatistics entries into Statistics 2024-01-17 14:22:17 +01:00
Rafikooo
a847aae5be
[Unit] Add more tests for sales statistics 2024-01-17 14:21:50 +01:00
Rafikooo
7177037cdf
[Unit] Update sales statistics response 2024-01-17 14:21:49 +01:00
Kamil Grygierzec
7819aefa96
Resend confirmation email using parameter 2024-01-16 12:51:30 +01:00
Kamil Grygierzec
3e0183ca52
cover tests 2024-01-16 12:51:29 +01:00
Wojdylak
7579bb2bbf
[CoreBundle] Change NotNull to NotBlank for channelCode in channelPricing 2024-01-05 13:15:32 +01:00
Wojdylak
a1ee97a031
[TestApi] Add response context assertion in assertJsonResponseViolations method 2024-01-05 13:04:50 +01:00
Wojdylak
7049df078a
[ApiBundle][ProductVariant] Unification of channelCode in channelPricing 2024-01-05 11:15:52 +01:00
Wojdylak
2dd549b031
[TestApi] Remove parameter status code in assertResponseViolations 2024-01-04 09:43:35 +01:00
Wojdylak
c1e8ef009b
[TestApi] Add assertions for code and header in assertResponseViolations 2024-01-04 09:34:38 +01:00
Wojdylak
97c5230ffa
[TestApi] Add new way of assert violations 2024-01-04 08:11:14 +01:00
Jacob Tobiasz
26cec53ed0
Resolve conflicts between 1.12 and 1.13 2023-12-24 08:37:42 +01:00
Jan Goralski
d896de175d
[Unit] Fix JsonApiTestCase constructor arguments 2023-12-22 09:11:03 +01:00
Jan Goralski
e002d791d9
[Locale] Add some more tests for header languange negotiation 2023-12-21 18:17:20 +01:00
gseric
3d5da057b8
[Locale] Change language negotiation from simple string comparison to RFC 4647 based 2023-12-21 18:11:44 +01:00
Jacob Tobiasz
ed578b3952
feature #15660 [API] Finish covering managing orders (TheMilek)
This PR was merged into the 1.13 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.13 <!-- see the comment below -->                  |
| Bug fix?        | no                                                     |
| New feature?    | yes                                                       |
| BC breaks?      | no                                                       |
| Deprecations?   | no <!-- don't forget to update the UPGRADE-*.md file --> |
| 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
-------
  Cover handling order shipment
  Cover accessing order from payments and shipments
  Cover preventing to view customers cart from the orders resource
  Remove no more valid scenarios
  Use SectionProvider in OrderExtension
  Move applyToCollection logic to private method and use in both cases
  Rename fulfilled_order file to fulfilled
  Add parameter for order state to filter out and fix the OrdrerExtension logic
2023-12-20 19:05:45 +01:00
Jacob Tobiasz
249eb7476f
minor #15639 [API][Admin] Finish covering product scenarios (NoResponseMate)
This PR was merged into the 1.13 branch.

Discussion
----------

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

Commits
-------
  [API][Admin] Finish covering product filtering
  [API][Admin] Finish covering product and product taxon sorting
  [API][Admin] More product related scenarios marked no-api
  [API][Admin] Cover seeing applied promotions on variants
  [API][Admin] Refactor viewing product suite split
  [API] Finish covering viewing product attributes
  [API][Admin] Cover managing product associations
  Cleanup
  [API] Cover viewing details of a product
  [Behat] Update step names in scenarios after changing name of steps
2023-12-20 18:48:40 +01:00
Kamil Grygierzec
99b2cacbd3
Cover contract tests 2023-12-20 17:38:40 +01:00
Kamil Grygierzec
fccadad26f
Rename fulfilled_order file to fulfilled 2023-12-20 16:01:05 +01:00
Kamil Grygierzec
fc6aea03a9
Cover preventing to view customers cart from the orders resource 2023-12-20 16:01:04 +01:00
Jacob Tobiasz
ee2768e843
feature #15663 [ApiBundle][Address] Add address log entries operation (Wojdylak)
This PR was merged into the 1.13 branch.

Discussion
----------

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

Commits
-------
  [ApiBundle][Address] Add address log entries operation
  [ApiBundle][Address] Rename GetAddressLogEntryAction to GetAddressLogEntryCollectionAction
2023-12-20 14:00:49 +01:00
Jan Goralski
41d35e26f1
Cleanup
[API] Unify position sorting
2023-12-20 13:47:53 +01:00
Jan Goralski
a9679a9591
[API][Admin] Cover managing product associations 2023-12-20 13:47:53 +01:00
Jan Goralski
8253bda642
[API][Admin] Cover seeing applied promotions on variants 2023-12-20 13:47:52 +01:00
Jan Goralski
6639ce0ae4
[API][Admin] Finish covering product and product taxon sorting 2023-12-20 13:47:52 +01:00
Jan Goralski
e71ee0de25
[API][Admin] Finish covering product filtering 2023-12-20 13:47:52 +01:00
Wojdylak
166009906a
[ApiBundle][Address] Add address log entries operation 2023-12-20 10:43:50 +01:00
Rafikooo
526958cbc5
[Unit] Add setUpOrderPlacer method in OrderPlacerTrait 2023-12-20 09:59:02 +01:00
Rafikooo
f94f4f6411
[Unit] Refactor tests that uses OrderPlacerTrait 2023-12-20 09:59:02 +01:00
Rafikooo
67caba6976
[Unit] Refactor OrderPlacerTrait 2023-12-20 09:59:02 +01:00
Jacob Tobiasz
323bd9ac59
Improve error handling while sending malformed amount value in the tax rate api resource update operation 2023-12-18 10:53:18 +01:00
Jan Góralski
e06f9165e9
minor #15630 Finish covering managing product-related resources (jakubtobiasz)
This PR was merged into the 1.13 branch.

Discussion
----------

| Q               | A                                                            |
|-----------------|--------------------------------------------------------------|
| Branch?         | 1.13
| Bug fix?        | no
| New feature?    | no
| BC breaks?      | no
| Deprecations?   | no
| Related tickets | n/a
| License         | MIT


Commits
-------
  Add missing @no-api tags in editing_product_review.feature
  Add missing @api tags in recalculating_product_average_rating.feature
  Cover scenarios in sorting_product_variants_within_product_by_position.feature
  Cover scenarios in filtering_product_reviews.feature
  Provide post-CR fixes
  Remove duplicated step
  [Behat][API] Minor improvements in managing variants contexts
  [Behat][API] Refactor scenarios of sorting variants to have the same for UI and API contexts
  [Behat] Fix scenario of browsing accepted reviews for case-sensitive PostreSQL
2023-12-18 09:14:32 +01:00
Jan Goralski
6180a8cbdc
[API][Admin] Allow using float for amount in tax rates 2023-12-15 16:25:24 +01:00
Grzegorz Sadowski
f578921582
refactor #15628 [PromotionBundle] Update validation process of promotion actions/rules (Wojdylak)
This PR was merged into the 1.13 branch.

Discussion
----------

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


Commits
-------

e530c7d9ca [PromotionBundle] Add parameters validation groups for promotion action and promotion rule
235c7e0dd5 [PromotionBundle] Move logic from PromotionActionGroupValidator to PromotionActionValidator
53c31aa420 [PromotionBundle] Move logic from PromotionRuleGroupValidator to PromotionRuleValidator
36d2a5ac08 [PromotionBundle] Remove constraints from FormType to avoid double constraints
d56ce734c6 Update upgrade file
c021e3e3a1 Add prefix sylius_ to validation groups
99a94b92a3 [PromotionBundle] Split PromotionActionValidator to PromotionActionGroupValidator and PromotionActionTypeValidator
de77a13d2d [PromotionBundle] Split PromotionRuleValidator to PromotionRuleGroupValidator and PromotionRuleTypeValidator
eb4a50c92b Update upgrade file
dd50a6f3a6 [PromotionBundle][PromotionAction] Add available type to validation message
633cf30ab3 [PromotionBundle][PromotionRule] Add available type to validation message
1494fce8fe [PromotionBundle] Add prefix to validation groups for promotion action/rule
2023-12-15 13:52:51 +01:00
Jacob Tobiasz
52da4090cb
Provide post-CR fixes 2023-12-15 06:42:59 +01:00
Wojdylak
633cf30ab3
[PromotionBundle][PromotionRule] Add available type to validation message 2023-12-14 09:58:53 +01:00
Wojdylak
dd50a6f3a6
[PromotionBundle][PromotionAction] Add available type to validation message 2023-12-14 09:58:42 +01:00