Resolve conflicts between 1.12 and 1.13

This commit is contained in:
Jacob Tobiasz 2024-03-09 06:45:51 +01:00
commit 280248c98c
No known key found for this signature in database
GPG key ID: 3F84290201B006E0
3124 changed files with 107126 additions and 23273 deletions

View file

@ -1,6 +1,6 @@
FROM sylius/standard:1.11-traditional
RUN apt-get update && apt-get install php8.0-xdebug && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*
RUN apt-get update && apt-get install curl php8.0-xdebug -y && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*
RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \
&& architecture=$(uname -m) \

49
.gitattributes vendored
View file

@ -1,8 +1,41 @@
/.docker export-ignore
/.github export-ignore
/adr export-ignore
/bin export-ignore
/config export-ignore
/docs export-ignore
/public export-ignore
docker-compose.*.yml export-ignore
/.bunnyshell export-ignore
/.docker export-ignore
/.github export-ignore
/adr export-ignore
/bin export-ignore
/config export-ignore
/docs export-ignore
/etd/build export-ignore
/public export-ignore
/templates export-ignore
/tests export-ignore
/translations export-ignore
/var export-ignore
.babelrc export-ignore
.dockerignore export-ignore
.editorconfig export-ignore
.env export-ignore
.env.* export-ignore
.eslintrc.js export-ignore
.gitattributes export-ignore
.gitignore export-ignore
.npmignore export-ignore
.readthedocs.yaml export-ignore
.symfony.insight.yaml export-ignore
composer-require-checker.json export-ignore
docker-compose.* export-ignore
ecs.php export-ignore
gulpfile.babel.js export-ignore
Makefile export-ignore
monorepo-builder.php export-ignore
package.json export-ignore
phparkitect.php export-ignore
phpspec.yml.dist export-ignore
phpstan.neon.dist export-ignore
phpstan-baseline.neon export-ignore
phpunit.xml.dist export-ignore
rector.php export-ignore
RoboFile.php export-ignore
symfony.lock export-ignore
webpack.config.js export-ignore
yaml-standards.yaml export-ignore

View file

@ -3,11 +3,16 @@ name: Auto-merge
on:
pull_request: ~
permissions:
contents: read
jobs:
auto-merge:
permissions:
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
-
name: Auto-merge minor dependencies upgrades

131
.github/workflows/ci__full_1_12.yaml vendored Normal file
View file

@ -0,0 +1,131 @@
name: Continuous Integration 1.12 (Full)
on:
schedule:
-
cron: "0 1 * * *" # Run every day at 1am
workflow_dispatch: ~
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}-1_12-full
cancel-in-progress: true
permissions:
contents: read
jobs:
static-checks:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] Static checks"
uses: ./.github/workflows/ci_static-checks.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mariadb:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] End-to-end tests (MariaDB)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mariadb.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mysql:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] End-to-end tests (MySQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mysql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-pgsql:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] End-to-end tests (PostgreSQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-pgsql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-custom:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] End-to-end tests (Custom)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-custom.yaml
with:
branch: ${{ matrix.branch }}
frontend:
name: Frontend
needs: static-checks
uses: ./.github/workflows/ci_frontend.yaml
with:
branch: ${{ matrix.branch }}
type: full
packages:
strategy:
matrix:
branch: [ "1.12" ]
name: "[${{ matrix.branch }}] Packages"
needs: static-checks
uses: ./.github/workflows/ci_packages.yaml
with:
branch: ${{ matrix.branch }}
type: full
unstable:
name: Unstable
needs: static-checks
uses: ./.github/workflows/ci__unstable.yaml
with:
ignore-failure: false
notify-about-build-status:
if: ${{ always() }}
name: "Notify about build status"
needs: [static-checks, e2e-mariadb, e2e-mysql, e2e-pgsql, e2e-custom, packages, unstable]
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: "Process data"
id: process-data
shell: bash
run: |
echo "branch=$(echo ${{ github.ref }} | sed 's/refs\/heads\///g' | sed 's/refs\/tags\///g')" >> $GITHUB_OUTPUT
echo "sha=$(echo ${{ github.sha }} | cut -c 1-12)" >> $GITHUB_OUTPUT
- name: "Notify on Slack"
uses: edge/simple-slack-notify@master
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
if: env.SLACK_WEBHOOK_URL != null
with:
channel: "#daily-build"
username: "GitHub Actions"
text: |
*<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} | ${{ github.workflow }} #${{ github.run_number }} build on ${{ github.repository }} repository has failed for ${{ steps.process-data.outputs.branch }} branch.>*
${{ needs.static-checks.result == 'success' && ':+1:' || ':x:' }} Static Checks
${{ needs.e2e-mariadb.result == 'success' && ':+1:' || ':x:' }} End-to-End (MariaDB)
${{ needs.e2e-mysql.result == 'success' && ':+1:' || ':x:' }} End-to-End (MySQL)
${{ needs.e2e-pgsql.result == 'success' && ':+1:' || ':x:' }} End-to-End (PostgreSQL)
${{ needs.e2e-custom.result == 'success' && ':+1:' || ':x:' }} End-to-End (Custom)
${{ needs.packages.result == 'success' && ':+1:' || ':x:' }} Packages
${{ needs.unstable.result == 'success' && ':+1:' || ':x:' }} Unstable
_ _ _ _ _ _ _
color: "danger"
fields: |
[
{ "title": "Repository", "value": "<https://github.com/${{ github.repository }} | ${{ github.repository }}>", "short": true },
{ "title": "Action", "value": "<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} | ${{ github.workflow }} #${{ github.run_number }}>", "short": true },
{ "title": "Reference", "value": "<https://github.com/${{ github.repository }}/tree/${{ steps.process-data.outputs.branch }} | ${{ steps.process-data.outputs.branch }}>", "short": true },
{ "title": "Commit", "value": "<https://github.com/${{ github.repository }}/commit/${{ github.sha }} | ${{ steps.process-data.outputs.sha }}>", "short": true },
{ "title": "Event", "value": "${{ github.event_name }}", "short": true }
]

131
.github/workflows/ci__full_1_13.yaml vendored Normal file
View file

@ -0,0 +1,131 @@
name: Continuous Integration 1.13 (Full)
on:
schedule:
-
cron: "0 2 * * *" # Run every day at 2am
workflow_dispatch: ~
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}-1_13-full
cancel-in-progress: true
permissions:
contents: read
jobs:
static-checks:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] Static checks"
uses: ./.github/workflows/ci_static-checks.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mariadb:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] End-to-end tests (MariaDB)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mariadb.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mysql:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] End-to-end tests (MySQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mysql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-pgsql:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] End-to-end tests (PostgreSQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-pgsql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-custom:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] End-to-end tests (Custom)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-custom.yaml
with:
branch: ${{ matrix.branch }}
frontend:
name: Frontend
needs: static-checks
uses: ./.github/workflows/ci_frontend.yaml
with:
branch: ${{ matrix.branch }}
type: full
packages:
strategy:
matrix:
branch: [ "1.13" ]
name: "[${{ matrix.branch }}] Packages"
needs: static-checks
uses: ./.github/workflows/ci_packages.yaml
with:
branch: ${{ matrix.branch }}
type: full
unstable:
name: Unstable
needs: static-checks
uses: ./.github/workflows/ci__unstable.yaml
with:
ignore-failure: false
notify-about-build-status:
if: ${{ always() }}
name: "Notify about build status"
needs: [static-checks, e2e-mariadb, e2e-mysql, e2e-pgsql, e2e-custom, packages, unstable]
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: "Process data"
id: process-data
shell: bash
run: |
echo "branch=$(echo ${{ github.ref }} | sed 's/refs\/heads\///g' | sed 's/refs\/tags\///g')" >> $GITHUB_OUTPUT
echo "sha=$(echo ${{ github.sha }} | cut -c 1-12)" >> $GITHUB_OUTPUT
- name: "Notify on Slack"
uses: edge/simple-slack-notify@master
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
if: env.SLACK_WEBHOOK_URL != null
with:
channel: "#daily-build"
username: "GitHub Actions"
text: |
*<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} | ${{ github.workflow }} #${{ github.run_number }} build on ${{ github.repository }} repository has failed for ${{ steps.process-data.outputs.branch }} branch.>*
${{ needs.static-checks.result == 'success' && ':+1:' || ':x:' }} Static Checks
${{ needs.e2e-mariadb.result == 'success' && ':+1:' || ':x:' }} End-to-End (MariaDB)
${{ needs.e2e-mysql.result == 'success' && ':+1:' || ':x:' }} End-to-End (MySQL)
${{ needs.e2e-pgsql.result == 'success' && ':+1:' || ':x:' }} End-to-End (PostgreSQL)
${{ needs.e2e-custom.result == 'success' && ':+1:' || ':x:' }} End-to-End (Custom)
${{ needs.packages.result == 'success' && ':+1:' || ':x:' }} Packages
${{ needs.unstable.result == 'success' && ':+1:' || ':x:' }} Unstable
_ _ _ _ _ _ _
color: "danger"
fields: |
[
{ "title": "Repository", "value": "<https://github.com/${{ github.repository }} | ${{ github.repository }}>", "short": true },
{ "title": "Action", "value": "<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} | ${{ github.workflow }} #${{ github.run_number }}>", "short": true },
{ "title": "Reference", "value": "<https://github.com/${{ github.repository }}/tree/${{ steps.process-data.outputs.branch }} | ${{ steps.process-data.outputs.branch }}>", "short": true },
{ "title": "Commit", "value": "<https://github.com/${{ github.repository }}/commit/${{ github.sha }} | ${{ steps.process-data.outputs.sha }}>", "short": true },
{ "title": "Event", "value": "${{ github.event_name }}", "short": true }
]

View file

@ -1,51 +1,83 @@
name: Continuous Integration (Full)
name: Continuous Integration 2.0 (Full)
on:
schedule:
-
cron: "0 3 * * *" # Run every day at 3am
workflow_dispatch: ~
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}-full
group: ci-${{ github.workflow }}-${{ github.ref }}-2_0-full
cancel-in-progress: true
permissions:
contents: read
jobs:
static-checks:
name: Static checks
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] Static checks"
uses: ./.github/workflows/ci_static-checks.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mariadb:
name: End-to-end tests (MariaDB)
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] End-to-end tests (MariaDB)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mariadb.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-mysql:
name: End-to-end tests (MySQL)
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] End-to-end tests (MySQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-mysql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-pgsql:
name: End-to-end tests (PostgreSQL)
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] End-to-end tests (PostgreSQL)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-pgsql.yaml
with:
branch: ${{ matrix.branch }}
type: full
e2e-custom:
name: End-to-end tests (Custom)
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] End-to-end tests (Custom)"
needs: static-checks
uses: ./.github/workflows/ci_e2e-custom.yaml
with:
branch: ${{ matrix.branch }}
frontend:
name: Frontend
needs: static-checks
uses: ./.github/workflows/ci_frontend.yaml
with:
branch: ${{ matrix.branch }}
type: full
packages:
name: Packages
strategy:
matrix:
branch: [ "2.0" ]
name: "[${{ matrix.branch }}] Packages"
needs: static-checks
uses: ./.github/workflows/ci_packages.yaml
with:
branch: ${{ matrix.branch }}
type: full
unstable:
name: Unstable

View file

@ -9,12 +9,16 @@ on:
workflow_dispatch: ~
push:
branches-ignore:
- 'dependabot/**'
- 'upmerge/**'
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}-minimal
cancel-in-progress: true
permissions:
contents: read
jobs:
static-checks:
name: Static checks

View file

@ -19,6 +19,9 @@ concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}-unstable
cancel-in-progress: true
permissions:
contents: read
jobs:
e2e-unstable:
name: End-to-end tests (Unstable)

View file

@ -2,7 +2,16 @@ name: End-to-End (Custom)
on:
workflow_dispatch: ~
workflow_call: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
permissions:
contents: read
jobs:
behat-no-js-unstable-symfony:
@ -22,8 +31,26 @@ jobs:
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=${{ matrix.mysql }}"
steps:
-
uses: actions/checkout@v3
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Change minimum-stability to dev
run: |
@ -31,16 +58,17 @@ jobs:
composer config prefer-stable true
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-php-${{ matrix.php }}-symfony-${{ matrix.symfony }}-"
cache_restore_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-php-${{ matrix.php }}-symfony-${{ matrix.symfony }}-"
e2e: "yes"
database_version: ${{ matrix.mysql }}
legacy_postgresql_setup: ${{ env.USE_LEGACY_POSTGRES_SETUP }}
php_version: ${{ matrix.php }}
symfony_version: ${{ matrix.symfony }}
- name: Run PHPUnit
continue-on-error: true
run: vendor/bin/phpunit --colors=always

View file

@ -4,11 +4,19 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
type: string
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -16,9 +24,17 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
-
name: "Get matrix"
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
uses: actions/checkout@v4
if: "${{ inputs.branch == '' }}"
- name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
with:
@ -28,7 +44,7 @@ jobs:
behat-no-js:
needs: get-matrix
runs-on: ubuntu-latest
name: "Non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MariaDB ${{ matrix.mariadb }}, DBAL ${{ matrix.dbal }}"
name: "Non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MariaDB ${{ matrix.mariadb }}, State Machine Adapter ${{ matrix.state_machine_adapter }}"
timeout-minutes: 45
strategy:
fail-fast: false
@ -37,17 +53,32 @@ jobs:
env:
APP_ENV: test_cached
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=mariadb-${{ matrix.mariadb }}"
TEST_SYLIUS_STATE_MACHINE_ADAPTER: "${{ matrix.state_machine_adapter }}"
steps:
-
uses: actions/checkout@v3
- name: Restrict packages
if: matrix.dbal == '^2.7'
run: composer require --no-update --no-scripts --no-interaction "doctrine/dbal:${{ matrix.dbal }}"
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-php-${{ matrix.php }}-symfony-${{ matrix.symfony }}-"
@ -55,6 +86,7 @@ jobs:
e2e: "yes"
database: "mariadb"
database_version: ${{ matrix.mariadb }}
legacy_postgresql_setup: ${{ env.USE_LEGACY_POSTGRES_SETUP }}
php_version: ${{ matrix.php }}
symfony_version: ${{ matrix.symfony }}
@ -74,7 +106,7 @@ jobs:
uses: actions/upload-artifact@v3
if: failure()
with:
name: "Logs (non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MariaDB ${{ matrix.mariadb }}), DBAL ${{ matrix.dbal }}"
name: "Logs (non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MariaDB ${{ matrix.mariadb }})"
path: |
etc/build/
var/log

View file

@ -4,11 +4,19 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
type: string
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -16,7 +24,15 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
uses: actions/checkout@v4
if: "${{ inputs.branch == '' }}"
-
name: "Get matrix"
id: matrix
@ -28,7 +44,7 @@ jobs:
behat-no-js:
needs: get-matrix
runs-on: ubuntu-latest
name: "Non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}, Twig ${{ matrix.twig }}, DBAL ${{ matrix.dbal }}.x, API Platform ${{ matrix.api-platform }}"
name: "Non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}, Twig ${{ matrix.twig }}, API Platform ${{ matrix.api-platform }}"
timeout-minutes: 45
strategy:
fail-fast: false
@ -39,25 +55,40 @@ jobs:
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=${{ matrix.mysql }}"
steps:
-
uses: actions/checkout@v3
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Restrict Twig
if: matrix.twig == '^2.12'
run: composer require --no-update --no-scripts --no-interaction "twig/twig:${{ matrix.twig }}"
- name: Restrict DBAL
if: matrix.dbal == '^2.7'
run: composer require --no-update --no-scripts --no-interaction "doctrine/dbal:${{ matrix.dbal }}"
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-api-platform-${{ matrix.api-platform }}"
cache_restore_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-api-platform-${{ matrix.api-platform }}"
e2e: "yes"
database_version: ${{ matrix.mysql }}
legacy_postgresql_setup: ${{ env.USE_LEGACY_POSTGRES_SETUP }}
php_version: ${{ matrix.php }}
symfony_version: ${{ matrix.symfony }}
@ -80,7 +111,7 @@ jobs:
uses: actions/upload-artifact@v3
if: failure()
with:
name: "Logs (non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}), ApiPlatform ${{ matrix.api-platform }}, Twig ${{ matrix.twig }}, MySQL ${{ matrix.mysql }}, DBAL ${{ matrix.dbal }}"
name: "Logs (non-JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}), ApiPlatform ${{ matrix.api-platform }}, Twig ${{ matrix.twig }}, MySQL ${{ matrix.mysql }}"
path: |
etc/build/
var/log
@ -89,7 +120,7 @@ jobs:
behat-ui-js:
needs: get-matrix
runs-on: ubuntu-latest
name: "JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}, Twig ${{ matrix.twig }}, DBAL ${{ matrix.dbal }}, API Platform ${{ matrix.api-platform }}"
name: "JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}, Twig ${{ matrix.twig }}, API Platform ${{ matrix.api-platform }}"
timeout-minutes: 45
strategy:
fail-fast: false
@ -100,8 +131,26 @@ jobs:
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=${{ matrix.mysql }}"
steps:
-
uses: actions/checkout@v3
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Get Composer cache directory
id: composer-cache
@ -118,12 +167,8 @@ jobs:
if: matrix.twig == '^2.12'
run: composer require --no-update --no-scripts --no-interaction "twig/twig:${{ matrix.twig }}"
- name: Restrict DBAL
if: matrix.dbal == '^2.7'
run: composer require --no-update --no-scripts --no-interaction "doctrine/dbal:${{ matrix.dbal }}"
- name: Build application
uses: jakubtobiasz/SyliusBuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-api-platform-${{ matrix.api-platform }}"
@ -131,12 +176,14 @@ jobs:
e2e: "yes"
e2e_js: "yes"
database_version: ${{ matrix.mysql }}
legacy_postgresql_setup: ${{ env.USE_LEGACY_POSTGRES_SETUP }}
php_version: ${{ matrix.php }}
symfony_version: ${{ matrix.symfony }}
node_version: "20.x"
- name: Install Behat driver
run: vendor/bin/bdi detect drivers
- name: Run Behat (Chromedriver)
run: vendor/bin/behat --colors --strict --no-interaction -vvv -f progress --tags="@mink:chromedriver&&~@todo&&~@cli" --suite-tags="@ui" || vendor/bin/behat --colors --strict --no-interaction -vvv -f progress --tags="@mink:chromedriver&&~@todo&&~@cli" --suite-tags="@ui" --rerun
@ -147,7 +194,7 @@ jobs:
uses: actions/upload-artifact@v3
if: failure()
with:
name: "Logs (JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, ApiPlatform ${{ matrix.api-platform }}, Twig ${{ matrix.twig }}, MySQL ${{ matrix.mysql }}, DBAL ${{ matrix.dbal }})"
name: "Logs (JS, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, ApiPlatform ${{ matrix.api-platform }}, Twig ${{ matrix.twig }}, MySQL ${{ matrix.mysql }})"
path: |
etc/build/
var/log

View file

@ -4,11 +4,19 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
type: string
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -16,7 +24,7 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
@ -38,11 +46,29 @@ jobs:
DATABASE_URL: "pgsql://postgres:postgres@127.0.0.1/sylius?charset=utf8&serverVersion=${{ matrix.postgres }}"
steps:
-
uses: actions/checkout@v3
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-php-${{ matrix.php }}-symfony-${{ matrix.symfony }}-"
@ -50,6 +76,7 @@ jobs:
e2e: "yes"
database: "postgresql"
database_version: ${{ matrix.postgres }}
legacy_postgresql_setup: ${{ env.USE_LEGACY_POSTGRES_SETUP }}
php_version: ${{ matrix.php }}
symfony_version: ${{ matrix.symfony }}

View file

@ -10,6 +10,9 @@ on:
default: false
workflow_dispatch: ~
permissions:
contents: read
jobs:
behat-no-js-unstable:
runs-on: ubuntu-latest
@ -29,7 +32,7 @@ jobs:
steps:
-
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Change minimum-stability to dev
run: |
@ -37,7 +40,7 @@ jobs:
composer config prefer-stable false
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
uses: SyliusLabs/BuildTestAppAction@v2.2
with:
build_type: "sylius"
cache_key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-php-${{ matrix.php }}-symfony-${{ matrix.symfony }}-"

View file

@ -4,6 +4,11 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
@ -16,13 +21,22 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- name: "Get matrix"
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
uses: actions/checkout@v4
if: "${{ inputs.branch == '' }}"
-
name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
with:
path: '.github/workflows/matrix.json'
prop_path: '${{ inputs.type }}.frontend'
prop_path: '${{ inputs.type }}.e2e-mysql'
frontend:
needs: get-matrix
@ -37,8 +51,26 @@ jobs:
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=8.0"
steps:
-
uses: actions/checkout@v3
- name: Set variables
shell: bash
env:
BRANCH: ${{ inputs.branch }}
run: |
if [ "$BRANCH" == "1.12" ]; then
echo "USE_LEGACY_POSTGRES_SETUP=yes" >> $GITHUB_ENV
else
echo "USE_LEGACY_POSTGRES_SETUP=no" >> $GITHUB_ENV
fi
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Build application
uses: SyliusLabs/BuildTestAppAction@v2.0
@ -47,5 +79,5 @@ jobs:
e2e_js: "yes"
database_version: "8.0"
php_version: "8.1"
symfony_version: "6.4.*"
symfony_version: "^6.4"
node_version: ${{ matrix.node }}

View file

@ -14,6 +14,9 @@ on:
type: boolean
default: false
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -21,7 +24,7 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
@ -34,7 +37,7 @@ jobs:
runs-on: ubuntu-latest
name: "PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }} (Unstable Dependencies)"
timeout-minutes: 25
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.get-matrix.outputs.matrix) }}
@ -46,7 +49,7 @@ jobs:
steps:
-
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
@ -65,7 +68,7 @@ jobs:
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache Composer
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-"

View file

@ -4,11 +4,19 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
type: string
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -16,7 +24,16 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
@ -30,7 +47,16 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: "Get matrix"
id: matrix
uses: notiz-dev/github-action-json-property@release
@ -47,15 +73,22 @@ jobs:
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.get-matrix.outputs.matrix) }}
env:
COMPOSER_ROOT_VERSION: "dev-main"
SYMFONY_VERSION: "${{ matrix.symfony }}"
UNSTABLE: "no"
steps:
-
uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
@ -75,19 +108,19 @@ jobs:
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache Composer
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-"
restore-keys: |
"${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-"
- name: Install dependencies
run: composer update --no-interaction --no-scripts
- name: "Run pipeline"
run: find src/Sylius -mindepth 3 -maxdepth 3 -type f -name composer.json -exec dirname '{}' \; | sed -e 's/src\/Sylius\///g' | sort | jq --raw-input . | jq --slurp . | jq -c . | xargs -0 vendor/bin/robo ci:packages
test_with_swiftmailer:
needs: get-matrix-swiftmailer
runs-on: ubuntu-latest
@ -97,7 +130,7 @@ jobs:
strategy:
fail-fast: false
matrix: ${{fromJson(needs.get-matrix-swiftmailer.outputs.matrix)}}
env:
APP_ENV: "test_with_swiftmailer"
COMPOSER_ROOT_VERSION: "dev-main"
@ -107,8 +140,15 @@ jobs:
PACKAGES: '["Bundle/CoreBundle", "Bundle/ApiBundle", "Bundle/AdminBundle"]'
steps:
-
uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
@ -122,13 +162,13 @@ jobs:
composer global config --no-plugins allow-plugins.symfony/flex true
composer global require --no-progress --no-scripts --no-plugins "symfony/flex:^2.4"
composer config extra.symfony.require "${{ matrix.symfony }}"
- name: Get Composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache Composer
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: "${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-"

View file

@ -4,11 +4,19 @@ on:
workflow_dispatch: ~
workflow_call:
inputs:
branch:
description: "Branch"
required: false
type: string
default: ""
type:
description: "Type of the build"
required: true
type: string
permissions:
contents: read
jobs:
get-matrix:
runs-on: ubuntu-latest
@ -16,7 +24,16 @@ jobs:
outputs:
matrix: ${{ steps.matrix.outputs.prop }}
steps:
- uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
-
name: "Get matrix"
id: matrix
@ -36,8 +53,15 @@ jobs:
APP_ENV: test_cached
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=8.0"
steps:
-
uses: actions/checkout@v3
- name: "Checkout (With Branch)"
if: "${{ inputs.branch != '' }}"
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: "Checkout"
if: "${{ inputs.branch == '' }}"
uses: actions/checkout@v4
- name: "Setup PHP"
uses: shivammathur/setup-php@v2
@ -64,12 +88,16 @@ jobs:
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: "Setup cache"
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
${{ steps.composer-cache.outputs.dir }}
key: ${{ github.run_id }}-${{ runner.os }}-${{ hashFiles('composer.json') }}-symfony-${{ matrix.symfony }}-api-platform-${{ matrix.api-platform }}
- name: "Require ext-random"
if: matrix.php == '8.2'
run: composer require ext-random --no-update --no-scripts --no-interaction
- name: "Install dependencies"
run: composer update --no-interaction --no-scripts

View file

@ -16,6 +16,9 @@ on:
cron: "0 1 * * 6" # Run at 1am every Saturday
workflow_dispatch: ~
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
@ -26,7 +29,7 @@ jobs:
steps:
-
uses: actions/checkout@v3
uses: actions/checkout@v4
-
name: Install documentation dependencies

View file

@ -3,12 +3,12 @@
"static-checks": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4",
"api-platform": "^2.7.10"
},
{
"php": "8.1",
"php": "8.2",
"symfony": "^6.4",
"api-platform": "^2.7.10"
}
@ -17,48 +17,47 @@
"e2e-mariadb": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4",
"mariadb": "10.4.10",
"dbal": "^2.7"
"state_machine_adapter": "winzou_state_machine"
},
{
"php": "8.1",
"php": "8.2",
"symfony": "^6.4",
"mariadb": "10.4.10",
"dbal": "^3.0"
"dbal": "^3.0",
"state_machine_adapter": "symfony_workflow"
}
]
},
"e2e-mysql": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4",
"api-platform": "^2.7.10",
"mysql": "5.7",
"twig": "^2.12",
"dbal": "^2.7"
"mysql": "8.0",
"twig": "^2.12"
},
{
"php": "8.1",
"php": "8.2",
"symfony": "^6.4",
"api-platform": "^2.7.10",
"mysql": "8.0",
"twig": "^3.3",
"dbal": "^3.0"
"twig": "^3.3"
}
]
},
"e2e-pgsql": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4",
"postgres": "13.9"
},
{
"php": "8.1",
"php": "8.2",
"symfony": "^6.4",
"postgres": "14.6"
}
@ -74,11 +73,11 @@
"packages": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4"
},
{
"php": "8.1",
"php": "8.2",
"symfony": "^6.4"
}
]
@ -86,7 +85,7 @@
"packages-swiftmailer": {
"include": [
{
"php": "8.0",
"php": "8.1",
"symfony": "^5.4"
}
]
@ -94,103 +93,39 @@
},
"full": {
"static-checks": {
"php": [ "8.0", "8.1" ],
"php": [ "8.1", "8.2" ],
"symfony": [ "^5.4", "^6.4" ],
"api-platform": [ "^2.7.10" ],
"exclude": [
{
"php": "8.0",
"symfony": "^6.4"
}
]
"api-platform": [ "^2.7.10" ]
},
"e2e-mariadb": {
"php": [ "8.0", "8.1" ],
"php": [ "8.1", "8.2" ],
"symfony": [ "^5.4", "^6.4" ],
"mariadb": [ "10.4.10" ],
"dbal": [ "^2.7", "^3.0" ],
"exclude": [
{
"php": "8.0",
"symfony": "^6.4"
}
]
"state_machine_adapter": [ "winzou_state_machine", "symfony_workflow" ]
},
"e2e-mysql": {
"php": [ "8.0", "8.1" ],
"php": [ "8.1", "8.2" ],
"symfony": [ "^5.4", "^6.4" ],
"api-platform": [ "^2.7.10" ],
"mysql": [ "5.7", "8.0" ],
"mysql": [ "8.0" ],
"twig": [ "^3.3" ],
"dbal": [ "^3.0" ],
"include": [
{
"php": "8.0",
"symfony": "^5.4",
"api-platform": "^2.7.10",
"mysql": "5.7",
"twig": "^2.12",
"dbal": "^3.0"
},
{
"php": "8.0",
"symfony": "^5.4",
"api-platform": "^2.7.10",
"mysql": "5.7",
"twig": "^2.12",
"dbal": "^2.7"
},
{
"php": "8.1",
"symfony": "^5.4",
"api-platform": "^2.7.10",
"mysql": "8.0",
"twig": "^3.3",
"dbal": "^3.0"
},
{
"php": "8.1",
"symfony": "~6.3.0",
"api-platform": "^2.7.10",
"mysql": "8.0",
"twig": "^3.3",
"dbal": "^3.0"
},
{
"php": "8.1",
"symfony": "^6.4",
"api-platform": "^2.7.10",
"mysql": "8.0",
"twig": "^3.3",
"dbal": "^3.0"
}
],
"exclude": [
{
"php": "8.0",
"symfony": "^6.4"
"twig": "^2.12"
}
]
},
"e2e-pgsql": {
"php": [ "8.0", "8.1" ],
"php": [ "8.1", "8.2" ],
"symfony": [ "^5.4", "^6.4" ],
"postgres": [ "13.9", "14.6" ],
"exclude": [
{
"php": "8.0",
"symfony": "^6.4"
}
]
"postgres": [ "13.9", "14.6" ]
},
"frontend": {
"include": [
{
"node": "14.x"
},
{
"node": "16.x"
},
{
"node": "18.x"
},
@ -200,17 +135,11 @@
]
},
"packages": {
"php": [ "8.0", "8.1" ],
"symfony": [ "^5.4", "^6.4" ],
"exclude": [
{
"php": "8.0",
"symfony": "^6.4"
}
]
"php": [ "8.1", "8.2" ],
"symfony": [ "^5.4", "^6.4" ]
},
"packages-swiftmailer": {
"php": [ "8.0", "8.1" ],
"php": [ "8.1" ],
"symfony": [ "^5.4" ]
}
}

View file

@ -3,9 +3,13 @@ name: Refactor
on:
schedule:
-
cron: "0 2 * * MON" # Run at 2am every Monday
cron: "0 2 * * *" # Run every day at 2am
workflow_dispatch: ~
permissions:
contents: write
pull-requests: write
jobs:
coding-standard:
runs-on: ubuntu-latest
@ -19,11 +23,17 @@ jobs:
strategy:
fail-fast: false
matrix:
branch: ["1.11", "1.12", "1.13"]
include:
-
branch: "1.12"
php: "8.0"
-
branch: "1.13"
php: "8.1"
steps:
-
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ matrix.branch }}
@ -31,7 +41,7 @@ jobs:
name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.0 # the lowest PHP version working with ECS
php-version: ${{ matrix.php }}
-
name: Install PHP dependencies

View file

@ -4,12 +4,15 @@ on:
release:
types: [created]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Get current date
id: date

73
.github/workflows/upmerge_pr.yaml vendored Normal file
View file

@ -0,0 +1,73 @@
name: Upmerge PR
on:
schedule:
-
cron: "0 2 * * *"
workflow_dispatch: ~
permissions:
contents: write
pull-requests: write
jobs:
upmerge:
runs-on: ubuntu-latest
if: github.repository == 'Sylius/Sylius'
name: "Upmerge PR"
timeout-minutes: 5
strategy:
fail-fast: false
matrix:
include:
-
base_branch: "1.12"
target_branch: "1.13"
-
base_branch: "1.13"
target_branch: "2.0"
-
base_branch: "2.0"
target_branch: "bootstrap-admin-panel"
steps:
-
uses: actions/checkout@v4
with:
ref: ${{ matrix.target_branch }}
-
name: Reset upmerge branch
run: |
git fetch origin ${{ matrix.base_branch }}:${{ matrix.base_branch }}
git reset --hard ${{ matrix.base_branch }}
-
name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.SYLIUS_BOT_PAT }}
title: '[UPMERGE] ${{ matrix.base_branch }} -> ${{ matrix.target_branch }}'
body: |
This PR has been generated automatically.
For more details see [upmerge_pr.yaml](/Sylius/Sylius/blob/1.13/.github/workflows/upmerge_pr.yaml).
**Remember!** The upmerge should always be merged with using `Merge pull request` button.
In case of conflicts, please resolve them manually with usign the following commands:
```
git fetch upstream
gh pr checkout <this-pr-number>
git merge upstream/${{ matrix.target_branch }} -m "Resolve conflicts between ${{ matrix.base_branch }} and ${{ matrix.target_branch }}"
```
If you use other name for the upstream remote, please replace `upstream` with the name of your remote pointing to the `Sylius/Sylius` repository.
Once the conflicts are resolved, please run `git merge --continue` and change the commit title to
```
Resolve conflicts between ${{ matrix.base_branch }} and ${{ matrix.target_branch }}
```
branch: "upmerge/${{ matrix.base_branch }}_${{ matrix.target_branch }}"
delete-branch: true
branch-suffix: "short-commit-hash"
base: ${{ matrix.target_branch }}

1
.gitignore vendored
View file

@ -60,4 +60,5 @@ docker-compose.override.yml
/public/build/
npm-debug.log
yarn-error.log
yarn.lock
###< symfony/webpack-encore-bundle ###

1
.npmignore Normal file
View file

@ -0,0 +1 @@
**/**

371
CHANGELOG-1.13.md Normal file
View file

@ -0,0 +1,371 @@
# CHANGELOG FOR `1.13.X`
## v1.13.0-ALPHA.1 (2024-02-05)
#### Details
- [#14379](https://github.com/Sylius/Sylius/issues/14379) [Admin] Cart promotions translations for labels ([@ernestWarwas](https://github.com/ernestWarwas))
- [#14483](https://github.com/Sylius/Sylius/issues/14483) Updating the RemoveExpiredCartCommand ([@mamazu](https://github.com/mamazu))
- [#14502](https://github.com/Sylius/Sylius/issues/14502) [Maintenance] Improve deprecation notice ([@lchrusciel](https://github.com/lchrusciel))
- [#14519](https://github.com/Sylius/Sylius/issues/14519) Refresh readme banner ([@kulczy](https://github.com/kulczy))
- [#14478](https://github.com/Sylius/Sylius/issues/14478) Add PaymentFixture ([@TheMilek](https://github.com/TheMilek))
- [#14550](https://github.com/Sylius/Sylius/issues/14550) [Admin][Customer] Filtering customers by groups ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14565](https://github.com/Sylius/Sylius/issues/14565) [Order] Add cart summary event ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14485](https://github.com/Sylius/Sylius/issues/14485) Adding a filter for state in product review grid ([@mamazu](https://github.com/mamazu))
- [#14529](https://github.com/Sylius/Sylius/issues/14529) Prepare for releasing @sylius-ui/frontend npm package ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14607](https://github.com/Sylius/Sylius/issues/14607) [CS][DX] Refactor
- [#14571](https://github.com/Sylius/Sylius/issues/14571) Create admin user with CLI ([@johbuch](https://github.com/johbuch), [@ernestWarwas](https://github.com/ernestWarwas), [@Rafikooo](https://github.com/Rafikooo))
- [#14568](https://github.com/Sylius/Sylius/issues/14568) [Catalog Promotions] Put catalog promotions into the processing state right after the delete request and keep this state until being removed ([@coldic3](https://github.com/coldic3))
- [#14660](https://github.com/Sylius/Sylius/issues/14660) [Maintenance] PHPUnit upgrade to ^9.5 ([@Rafikooo](https://github.com/Rafikooo))
- [#14654](https://github.com/Sylius/Sylius/issues/14654) Add a cookbook about dealing with multiple channels in console commands ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14629](https://github.com/Sylius/Sylius/issues/14629) [DX] Store passwords in plaintext in test environment ([@coldic3](https://github.com/coldic3))
- [#14658](https://github.com/Sylius/Sylius/issues/14658) [CS][DX] Refactor ([@bot](https://github.com/bot)@[@sylius](https://github.com/sylius).[@org](https://github.com/org))
- [#14668](https://github.com/Sylius/Sylius/issues/14668) Improve "Handle multiple channels in CLI" cookbook ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14696](https://github.com/Sylius/Sylius/issues/14696) Remove yarn.lock file ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14708](https://github.com/Sylius/Sylius/issues/14708) Add missing final keywords to Spec tests ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14709](https://github.com/Sylius/Sylius/issues/14709) Drop unneeded @javascript tag ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14718](https://github.com/Sylius/Sylius/issues/14718) [CS][DX] Refactor
- [#14598](https://github.com/Sylius/Sylius/issues/14598) [API] Mapping/serialization cleanup ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14655](https://github.com/Sylius/Sylius/issues/14655) Improve error handling while password resetting ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14713](https://github.com/Sylius/Sylius/issues/14713) [Core] Optimize UnpaidOrdersStateUpdater ([@coldic3](https://github.com/coldic3))
- [#14693](https://github.com/Sylius/Sylius/issues/14693) [Feature] Allows `row_attr` on form rows ([@Prometee](https://github.com/Prometee))
- [#14724](https://github.com/Sylius/Sylius/issues/14724) As an Admin, I want to modify taxons of a product ([@everwhatever](https://github.com/everwhatever))
- [#14710](https://github.com/Sylius/Sylius/issues/14710) Refactor CI ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14732](https://github.com/Sylius/Sylius/issues/14732) [Fix] Mark PHPSpec class as final ([@Rafikooo](https://github.com/Rafikooo))
- [#13445](https://github.com/Sylius/Sylius/issues/13445) [Promotion] Add a label for filters ([@pjurasek](https://github.com/pjurasek))
- [#14581](https://github.com/Sylius/Sylius/issues/14581) Fix dev dockerfile: add curl ([@Nek-](https://github.com/Nek-))
- [#14734](https://github.com/Sylius/Sylius/issues/14734) Adjust GitHub Actions jobs' names ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14741](https://github.com/Sylius/Sylius/issues/14741) [CS][DX] Refactor
- [#14698](https://github.com/Sylius/Sylius/issues/14698) ApiBundle fixes in composer.js ([@dawkaa](https://github.com/dawkaa))
- [#14742](https://github.com/Sylius/Sylius/issues/14742) Refactor Workflows to use two type of builds ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14747](https://github.com/Sylius/Sylius/issues/14747) Make build notifier running always event on failed builds ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14665](https://github.com/Sylius/Sylius/issues/14665) [Feature][Command] CreateAdminUserCommand - add AdminUser entity validation ([@Rafikooo](https://github.com/Rafikooo))
- [#14737](https://github.com/Sylius/Sylius/issues/14737) Add a custom workflow for Symfony 6.3 ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14470](https://github.com/Sylius/Sylius/issues/14470) Update doctrine/cache requirement from ^1.10 to ^2.2 ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#14771](https://github.com/Sylius/Sylius/issues/14771) Change the scheduled hour for full workflow to be different than in 1.12 branch ([@GSadee](https://github.com/GSadee))
- [#14769](https://github.com/Sylius/Sylius/issues/14769) [CS][DX] Refactor
- [#14786](https://github.com/Sylius/Sylius/issues/14786) Fix CI Full to run both 1.12 and 1.13 ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14756](https://github.com/Sylius/Sylius/issues/14756) [API] Get admin detail information ([@dawkaa](https://github.com/dawkaa))
- [#14754](https://github.com/Sylius/Sylius/issues/14754) Add PHP 8.2 to workflows ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14728](https://github.com/Sylius/Sylius/issues/14728) [API] Fix admin's side can't create new taxonomy ([@dawkaa](https://github.com/dawkaa))
- [#12556](https://github.com/Sylius/Sylius/issues/12556) Add an option to use icon-only buttons on grids ([@loic425](https://github.com/loic425))
- [#13440](https://github.com/Sylius/Sylius/issues/13440) Add documentation for non-labeled actions ([@loic425](https://github.com/loic425))
- [#14790](https://github.com/Sylius/Sylius/issues/14790) Update RequestBuilder.php to PHP 8 new features ([@dawkaa](https://github.com/dawkaa))
- [#14794](https://github.com/Sylius/Sylius/issues/14794) [CS][DX] Refactor
- [#13045](https://github.com/Sylius/Sylius/issues/13045) Association hydrator private in product repo should be protected ([@Nek-](https://github.com/Nek-))
- [#14821](https://github.com/Sylius/Sylius/issues/14821) [CS][DX] Refactor
- [#14822](https://github.com/Sylius/Sylius/issues/14822) [CI] Remove PHP 8.2 from packages tests of the unmaintained Swiftmailer ([@GSadee](https://github.com/GSadee))
- [#14798](https://github.com/Sylius/Sylius/issues/14798) Reorder order's sidebar in admin ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14811](https://github.com/Sylius/Sylius/issues/14811) Cover managing the tax rates in API ([@hatem20](https://github.com/hatem20), [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14831](https://github.com/Sylius/Sylius/issues/14831) [CS][DX] Refactor
- [#14833](https://github.com/Sylius/Sylius/issues/14833) Allow to define a priority on autoconfigured order processors and cart contexts ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14840](https://github.com/Sylius/Sylius/issues/14840) [CS][DX] Refactor
- [#14843](https://github.com/Sylius/Sylius/issues/14843) Add a note about autoconfiguring order processor with an attribute ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14623](https://github.com/Sylius/Sylius/issues/14623) chore: tag OrderTaxesApplicatorInterface ([@Florian-Merle](https://github.com/Florian-Merle))
- [#14848](https://github.com/Sylius/Sylius/issues/14848) [Dependencies] Bump up API Platform to 2.7.10 ([@GSadee](https://github.com/GSadee))
- [#10690](https://github.com/Sylius/Sylius/issues/10690) [Attributes] Add FloatAttributeType Feature ([@panigrc](https://github.com/panigrc), [@TheMilek](https://github.com/TheMilek))
- [#14852](https://github.com/Sylius/Sylius/issues/14852) [PriceHistory] Behat scenarios ([@Rafikooo](https://github.com/Rafikooo))
- [#14860](https://github.com/Sylius/Sylius/issues/14860) [Behat][API] Common saving within contexts ([@Rafikooo](https://github.com/Rafikooo))
- [#14864](https://github.com/Sylius/Sylius/issues/14864) [TaxRate][UI] Add missing behat step implementation ([@Rafikooo](https://github.com/Rafikooo))
- [#14862](https://github.com/Sylius/Sylius/issues/14862) [Behat][PriceHistory] Adjust scenarios for displaying lowest price according to the excluded taxons ([@GSadee](https://github.com/GSadee))
- [#14854](https://github.com/Sylius/Sylius/issues/14854) [PriceHistory][API] ChannelPricingLogEntry implementation ([@Rafikooo](https://github.com/Rafikooo))
- [#14866](https://github.com/Sylius/Sylius/issues/14866) [PriceHistory][UI] ChannelPricingLogEntry implementation ([@Rafikooo](https://github.com/Rafikooo))
- [#14867](https://github.com/Sylius/Sylius/issues/14867) [Attributes] FloatType input type as a number instead of text ([@TheMilek](https://github.com/TheMilek))
- [#14846](https://github.com/Sylius/Sylius/issues/14846) [Shipment] Reduce amount of queries during shipping eligibility checking ([@lchrusciel](https://github.com/lchrusciel))
- [#12781](https://github.com/Sylius/Sylius/issues/12781) Add "enabled" property to API serialization ([@Nek-](https://github.com/Nek-))
- [#14676](https://github.com/Sylius/Sylius/issues/14676) Add EmailMessagesProvider ([@TheMilek](https://github.com/TheMilek))
- [#14890](https://github.com/Sylius/Sylius/issues/14890) [CS][DX] Refactor
- [#14872](https://github.com/Sylius/Sylius/issues/14872) Fix dependency security vulerability for enshrined/svg-sanitize package ([@cosminsandu](https://github.com/cosminsandu))
- [#14873](https://github.com/Sylius/Sylius/issues/14873) Improve displaying info about insufficient stock in the cart ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14882](https://github.com/Sylius/Sylius/issues/14882) [PriceHistory] Display of information about the lowest price before the discount & channel setup ([@Rafikooo](https://github.com/Rafikooo))
- [#14875](https://github.com/Sylius/Sylius/issues/14875) [PriceHistory] Add removing price history command feature ([@TheMilek](https://github.com/TheMilek))
- [#14893](https://github.com/Sylius/Sylius/issues/14893) [OAuth] Up access and refresh tokens' length ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14894](https://github.com/Sylius/Sylius/issues/14894) Avoid getting the theme if we have it already ([@jacquesbh](https://github.com/jacquesbh), [@NoResponseMate](https://github.com/NoResponseMate))
- [#14899](https://github.com/Sylius/Sylius/issues/14899) [PriceHistory] Extract config ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14903](https://github.com/Sylius/Sylius/issues/14903) [PriceHistory] Combine migrations into one ([@TheMilek](https://github.com/TheMilek))
- [#14904](https://github.com/Sylius/Sylius/issues/14904) [PriceHistory] Asynchronous lowest price processing ([@Rafikooo](https://github.com/Rafikooo))
- [#14909](https://github.com/Sylius/Sylius/issues/14909) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#14915](https://github.com/Sylius/Sylius/issues/14915) [Maintenance] Rename OnFlushEntityObserverListener service ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14916](https://github.com/Sylius/Sylius/issues/14916) [API][ProductTaxon] Add unique combination validation ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14900](https://github.com/Sylius/Sylius/issues/14900) [UpgradeFile] Introduce upgrade from Sylius 1.12 with PriceHistoryPlugin to Sylius 1.13 ([@TheMilek](https://github.com/TheMilek))
- [#14911](https://github.com/Sylius/Sylius/issues/14911) [PriceHistory] Add Compiler Pass for upgrade between Sylius 1.12 and Sylius 1.13 version ([@TheMilek](https://github.com/TheMilek))
- [#14928](https://github.com/Sylius/Sylius/issues/14928) [Maintenance] Add missing Spec for HasEnabledEntityValidator ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14837](https://github.com/Sylius/Sylius/issues/14837) [ProductVariant][API] Resource improvements ([@Rafikooo](https://github.com/Rafikooo))
- [#14930](https://github.com/Sylius/Sylius/issues/14930) [Maintenance] Fix schema update with longer UserOAuth tokens ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14931](https://github.com/Sylius/Sylius/issues/14931) [Behat][API] Checking out as guest with a registered email ([@coldic3](https://github.com/coldic3))
- [#14934](https://github.com/Sylius/Sylius/issues/14934) Cover accessing non-existing product via API scenario ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14933](https://github.com/Sylius/Sylius/issues/14933) Allow to filter products via API only by enabled taxon ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14943](https://github.com/Sylius/Sylius/issues/14943) Cover handling different currencies on multiple channels via API scenarios ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14939](https://github.com/Sylius/Sylius/issues/14939) [Behat][API] Add "no-api" tag to the changing payment method page scenario ([@coldic3](https://github.com/coldic3))
- [#14937](https://github.com/Sylius/Sylius/issues/14937) Add calculating OrderItemsSubtotal to the Order model ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14936](https://github.com/Sylius/Sylius/issues/14936) Cover applying correct taxes for shipping scenarios ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14922](https://github.com/Sylius/Sylius/issues/14922) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#14942](https://github.com/Sylius/Sylius/issues/14942) Cover applying correct taxes for shipping with tax rate included in price scenarios ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14947](https://github.com/Sylius/Sylius/issues/14947) Cover reapplying promotion on cart changes scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14921](https://github.com/Sylius/Sylius/issues/14921) [Fixtures] add possibility to configure shipping_address_in_checkout_required ([@BastienGoze](https://github.com/BastienGoze))
- [#14924](https://github.com/Sylius/Sylius/issues/14924) Update sylius/calendar requirement from ^0.3 || ^0.4 to ^0.5.0 ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)], [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14951](https://github.com/Sylius/Sylius/issues/14951) Cover Api steps in paying offline during checkout scenario ([@TheMilek](https://github.com/TheMilek))
- [#14960](https://github.com/Sylius/Sylius/issues/14960) Cover Api steps in paying offline during checkout as guest scenario ([@TheMilek](https://github.com/TheMilek))
- [#14959](https://github.com/Sylius/Sylius/issues/14959) [Behat][API] Retrying the payment with different Offline payment ([@coldic3](https://github.com/coldic3))
- [#14945](https://github.com/Sylius/Sylius/issues/14945) Add @no-api to redirecting_to_products_when_there_is_a_trailing_slash_in_path scenarios ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14948](https://github.com/Sylius/Sylius/issues/14948) Cover reverting previously applied discount on cart scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14885](https://github.com/Sylius/Sylius/issues/14885) [DX] Ease adding more data to variant options map ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14952](https://github.com/Sylius/Sylius/issues/14952) [DX] Improve ChannelCollector customizability and performance ([@coldic3](https://github.com/coldic3))
- [#14950](https://github.com/Sylius/Sylius/issues/14950) [Migrations] Support PostgreSQL migrations ([@Rafikooo](https://github.com/Rafikooo))
- [#14791](https://github.com/Sylius/Sylius/issues/14791) Add a taxon delete section ([@dawkaa](https://github.com/dawkaa))
- [#14964](https://github.com/Sylius/Sylius/issues/14964) Clean up conflicts for sylius/sylius ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#14989](https://github.com/Sylius/Sylius/issues/14989) [ProductTaxon][Product] Improve validation ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14975](https://github.com/Sylius/Sylius/issues/14975) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#14999](https://github.com/Sylius/Sylius/issues/14999) [CI] Change outdated GitHub action ([@Rafikooo](https://github.com/Rafikooo))
- [#14969](https://github.com/Sylius/Sylius/issues/14969) [DX] Removed obsolete templating helper ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14919](https://github.com/Sylius/Sylius/issues/14919) Use Symfony HTTP Client in place of Guzzle 6 by default and provide Guzzle 7 support ([@coldic3](https://github.com/coldic3))
- [#14584](https://github.com/Sylius/Sylius/issues/14584) Fix product review validation's notInRangeMessage ([@diimpp](https://github.com/diimpp))
- [#15004](https://github.com/Sylius/Sylius/issues/15004) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#15003](https://github.com/Sylius/Sylius/issues/15003) Cover seeing default shipping method scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15002](https://github.com/Sylius/Sylius/issues/15002) Cover product integrity scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15001](https://github.com/Sylius/Sylius/issues/15001) Cover editing customer profile scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15020](https://github.com/Sylius/Sylius/issues/15020) Cover Viewing only enabled taxons in taxon menu scenarios ([@TheMilek](https://github.com/TheMilek))
- [#15023](https://github.com/Sylius/Sylius/issues/15023) [Api][Maintenance] Remove ChannelContext from ProductVariantNormalizer ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15009](https://github.com/Sylius/Sylius/issues/15009) Replace `payum/payum` dependency with `payum/core` ([@rimas-kudelis](https://github.com/rimas-kudelis))
- [#15019](https://github.com/Sylius/Sylius/issues/15019) Update rector/rector requirement from ^0.15.13 to ^0.16.0 ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#14994](https://github.com/Sylius/Sylius/issues/14994) [Products][Taxon] Allowing deleting a taxon that is a main taxon of a product ([@Rafikooo](https://github.com/Rafikooo))
- [#15012](https://github.com/Sylius/Sylius/issues/15012) Update guzzlehttp/psr7 requirement from ^1.8 to ^2.5 ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#14968](https://github.com/Sylius/Sylius/issues/14968) Bump Psalm to v5 ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15036](https://github.com/Sylius/Sylius/issues/15036) Fix CI ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15035](https://github.com/Sylius/Sylius/issues/15035) Remove 1.11 from the refactor workflow ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15039](https://github.com/Sylius/Sylius/issues/15039) Fix CI ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15044](https://github.com/Sylius/Sylius/issues/15044) Add API tag to viewing products with disabled variants scenarios ([@TheMilek](https://github.com/TheMilek))
- [#15015](https://github.com/Sylius/Sylius/issues/15015) [API] Product variants with options ([@Rafikooo](https://github.com/Rafikooo))
- [#15046](https://github.com/Sylius/Sylius/issues/15046) [Maintenance] Removed autogenerated migration comments ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14480](https://github.com/Sylius/Sylius/issues/14480) Missing length validation for label in cart promotion translations ([@ernestWarwas](https://github.com/ernestWarwas))
- [#15045](https://github.com/Sylius/Sylius/issues/15045) Uncomment editing customer profile steps ([@TheMilek](https://github.com/TheMilek))
- [#14944](https://github.com/Sylius/Sylius/issues/14944) Cover inform customer about order total changes scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15042](https://github.com/Sylius/Sylius/issues/15042) View only enabled taxons ([@TheMilek](https://github.com/TheMilek))
- [#15028](https://github.com/Sylius/Sylius/issues/15028) Cover viewing product associations via API ([@TheMilek](https://github.com/TheMilek))
- [#15054](https://github.com/Sylius/Sylius/issues/15054) Cover viewing different price for different product variants API scenario ([@TheMilek](https://github.com/TheMilek))
- [#15047](https://github.com/Sylius/Sylius/issues/15047) Parametrize operations allowed to bypass filtering carts ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15043](https://github.com/Sylius/Sylius/issues/15043) [Maintenance] Add a note about PostgreSQL migrations support ([@Rafikooo](https://github.com/Rafikooo))
- [#15060](https://github.com/Sylius/Sylius/issues/15060) [Product] Add an alias to `ProductVariantResolverInterface` ([@coldic3](https://github.com/coldic3))
- [#15070](https://github.com/Sylius/Sylius/issues/15070) Upmerge 1.12 into 1.13 ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15066](https://github.com/Sylius/Sylius/issues/15066) [CS][DX] Refactor
- [#15083](https://github.com/Sylius/Sylius/issues/15083) Remove deprecated EventSubscriberInterface ([@TheMilek](https://github.com/TheMilek))
- [#15063](https://github.com/Sylius/Sylius/issues/15063) [API] Allow overriding xml resource mapping ([@NoResponseMate](https://github.com/NoResponseMate))
- [#14990](https://github.com/Sylius/Sylius/issues/14990) [API] Sorting user orders by order number ([@dawkaa](https://github.com/dawkaa))
- [#15096](https://github.com/Sylius/Sylius/issues/15096) [Fix] Remove redundant conflict entries ([@Rafikooo](https://github.com/Rafikooo))
- [#15071](https://github.com/Sylius/Sylius/issues/15071) Update vimeo/psalm requirement from 5.9.* to 5.12.* ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#15091](https://github.com/Sylius/Sylius/issues/15091) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#15095](https://github.com/Sylius/Sylius/issues/15095) Viewing children taxons API scenario ceverage ([@TheMilek](https://github.com/TheMilek))
- [#15103](https://github.com/Sylius/Sylius/issues/15103) Seeing order locale API scenario coverage ([@TheMilek](https://github.com/TheMilek))
- [#15098](https://github.com/Sylius/Sylius/issues/15098) Add @no-api tag to preventing to pay for cancelled order scenario ([@TheMilek](https://github.com/TheMilek))
- [#15068](https://github.com/Sylius/Sylius/issues/15068) View only available associations for product ([@TheMilek](https://github.com/TheMilek))
- [#15092](https://github.com/Sylius/Sylius/issues/15092) Cover Seeing payment method instructions behat API scenario ([@TheMilek](https://github.com/TheMilek))
- [#15104](https://github.com/Sylius/Sylius/issues/15104) Fixes after reviews ([@TheMilek](https://github.com/TheMilek))
- [#15085](https://github.com/Sylius/Sylius/issues/15085) [API][Products] Viewing diagonal variants options ([@Rafikooo](https://github.com/Rafikooo))
- [#15105](https://github.com/Sylius/Sylius/issues/15105) [Maintenance] Update the remaining copyright blocks ([@Rafikooo](https://github.com/Rafikooo))
- [#15106](https://github.com/Sylius/Sylius/issues/15106) [Maintenance] Update the remaining copyright blocks ([@Rafikooo](https://github.com/Rafikooo))
- [#15109](https://github.com/Sylius/Sylius/issues/15109) Add workflow for automatic upmerge PR creating ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15113](https://github.com/Sylius/Sylius/issues/15113) Fix auto upmerge workflow ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15112](https://github.com/Sylius/Sylius/issues/15112) [Scenarios] Add @no-api tag for `Addressing an order and sign in scenario` ([@Rafikooo](https://github.com/Rafikooo))
- [#15087](https://github.com/Sylius/Sylius/issues/15087) [Maintenance][API] Fix ChangedItemQuantityInCart validator alias ([@NoResponseMate](https://github.com/NoResponseMate), [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15084](https://github.com/Sylius/Sylius/issues/15084) Update Sylius 1.12 with PriceHistoryPlugin to Sylius 1.13 upgrade file ([@TheMilek](https://github.com/TheMilek))
- [#15061](https://github.com/Sylius/Sylius/issues/15061) Performance improvement of SingleChannelContext ([@coldic3](https://github.com/coldic3))
- [#15099](https://github.com/Sylius/Sylius/issues/15099) [Product] Composite variant resolver ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15121](https://github.com/Sylius/Sylius/issues/15121) Fix CI ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15122](https://github.com/Sylius/Sylius/issues/15122) [API] Cover signing in validation ([@Rafikooo](https://github.com/Rafikooo))
- [#15026](https://github.com/Sylius/Sylius/issues/15026) Allow removing locales ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15135](https://github.com/Sylius/Sylius/issues/15135) Revert "Add support for Bunnyshell (#15134)" ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15108](https://github.com/Sylius/Sylius/issues/15108) Prevent changing payment method of cancelled order ([@TheMilek](https://github.com/TheMilek))
- [#15132](https://github.com/Sylius/Sylius/issues/15132) Add joins on the orders list query builder conditionally ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15072](https://github.com/Sylius/Sylius/issues/15072) [API] Validate endpoints that uses commands ([@Rafikooo](https://github.com/Rafikooo))
- [#15138](https://github.com/Sylius/Sylius/issues/15138) [Bunnyshell] Adjust the workflows for Fork PRs ([@aris-bunnyshell](https://github.com/aris-bunnyshell))
- [#15143](https://github.com/Sylius/Sylius/issues/15143) Upmerge adjustments ([@Rafikooo](https://github.com/Rafikooo))
- [#15111](https://github.com/Sylius/Sylius/issues/15111) [API] Allow command IRI denormalization in arrays ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15158](https://github.com/Sylius/Sylius/issues/15158) [API] Replace Swagger with OpenAPI ([@coldic3](https://github.com/coldic3))
- [#15188](https://github.com/Sylius/Sylius/issues/15188) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#15190](https://github.com/Sylius/Sylius/issues/15190) Update vimeo/psalm requirement from 5.13.* to 5.14.* ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#15174](https://github.com/Sylius/Sylius/issues/15174) Update sonata-project/block-bundle requirement from ^4.2 to ^5.0 ([@dependabot](https://github.com/dependabot)[[@bot](https://github.com/bot)])
- [#15209](https://github.com/Sylius/Sylius/issues/15209) [Maintenance] Trigger deprecations in OrderPaymentProcessor ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15208](https://github.com/Sylius/Sylius/issues/15208) [Maintenance] Trigger deprecations in taxes applicators ([@GSadee](https://github.com/GSadee))
- [#15221](https://github.com/Sylius/Sylius/issues/15221) Add explicit mapping between product and reviews, and between product and attributes ([@GSadee](https://github.com/GSadee))
- [#15220](https://github.com/Sylius/Sylius/issues/15220) [Taxonomy][Form] Taxon slug generator including parent slug also in update mode ([@nicolalazzaro](https://github.com/nicolalazzaro), [@NoResponseMate](https://github.com/NoResponseMate))
- [#15235](https://github.com/Sylius/Sylius/issues/15235) [Maintenance] Note deprecation in SelectAttributeChoicesCollectionType ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15244](https://github.com/Sylius/Sylius/issues/15244) Refresh README.md ([@kulczy](https://github.com/kulczy))
- [#15056](https://github.com/Sylius/Sylius/issues/15056) Improve registration workflow ([@fabianaromagnoli](https://github.com/fabianaromagnoli), [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15254](https://github.com/Sylius/Sylius/issues/15254) Deprecate unused ProductOptionChoiceType ([@TheMilek](https://github.com/TheMilek))
- [#15259](https://github.com/Sylius/Sylius/issues/15259) [API][Admin] Taxons management ([@GSadee](https://github.com/GSadee))
- [#15292](https://github.com/Sylius/Sylius/issues/15292) Provide autoconfiguration with attributes for ApiBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15297](https://github.com/Sylius/Sylius/issues/15297) Provide autoconfiguration with attributes for PaymentBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15301](https://github.com/Sylius/Sylius/issues/15301) Provide autoconfiguration with attributes for PayumBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15293](https://github.com/Sylius/Sylius/issues/15293) Provide autoconfiguration with attributes for CoreBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15295](https://github.com/Sylius/Sylius/issues/15295) Provide autoconfiguration with attributes for LocaleBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15294](https://github.com/Sylius/Sylius/issues/15294) Provide autoconfiguration with attributes for CurrencyBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15296](https://github.com/Sylius/Sylius/issues/15296) Improve autoconfiguration with attributes for OrderBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15298](https://github.com/Sylius/Sylius/issues/15298) Improve autoconfiguration with attributes for ProductBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15304](https://github.com/Sylius/Sylius/issues/15304) Provide autoconfiguration with attributes for TaxationBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15303](https://github.com/Sylius/Sylius/issues/15303) Provide autoconfiguration with attributes for ShippingBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15302](https://github.com/Sylius/Sylius/issues/15302) Provide autoconfiguration with attributes for PromotionBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15299](https://github.com/Sylius/Sylius/issues/15299) Provide autoconfiguration with attributes for AttributeBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15300](https://github.com/Sylius/Sylius/issues/15300) Provide autoconfiguration with attributes for ChannelBundle ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15305](https://github.com/Sylius/Sylius/issues/15305) Add missing admin:taxon:update group to TaxonTranslation's locale field ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15307](https://github.com/Sylius/Sylius/issues/15307) Add a deprecation for the sylius_admin_ajax_taxon_move route ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15281](https://github.com/Sylius/Sylius/issues/15281) Only show "View More" button when there are accepted reviews ([@stefandoorn](https://github.com/stefandoorn), [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15278](https://github.com/Sylius/Sylius/issues/15278) Deprecate ContainsProductRuleUpdater and TotalOfItemsFromTaxonRuleUpdater ([@TheMilek](https://github.com/TheMilek))
- [#15309](https://github.com/Sylius/Sylius/issues/15309) Update the banner in the README.md ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15317](https://github.com/Sylius/Sylius/issues/15317) [doc] plugin naming - new plugin structure ([@oallain](https://github.com/oallain))
- [#15322](https://github.com/Sylius/Sylius/issues/15322) Add optional message to API cannot be removed exceptions ([@Wojdylak](https://github.com/Wojdylak))
- [#15323](https://github.com/Sylius/Sylius/issues/15323) [Maintenance] Change `trigger_error` to `trigger_deprecation` ([@Rafikooo](https://github.com/Rafikooo))
- [#15324](https://github.com/Sylius/Sylius/issues/15324) Prevent from removing taxon that is in use by a promotion rule ([@TheMilek](https://github.com/TheMilek))
- [#15315](https://github.com/Sylius/Sylius/issues/15315) Provide the State Machine abstraction ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15335](https://github.com/Sylius/Sylius/issues/15335) Minor typo fix in deprecation message in ZoneChoiceType ([@GSadee](https://github.com/GSadee))
- [#15333](https://github.com/Sylius/Sylius/issues/15333) [CoreBundle] Add missed deprecation block ([@Rafikooo](https://github.com/Rafikooo))
- [#15346](https://github.com/Sylius/Sylius/issues/15346) [Maintenance] Deprecate `OrderItemsSubtotalCalculatorInterface` ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15351](https://github.com/Sylius/Sylius/issues/15351) [AdminBundle] Corrected deprecation messages ([@Rafikooo](https://github.com/Rafikooo))
- [#15338](https://github.com/Sylius/Sylius/issues/15338) [CoreBundle] Move the PaymentFixture class in a proper namespace and deprecate other code ([@Rafikooo](https://github.com/Rafikooo))
- [#15288](https://github.com/Sylius/Sylius/issues/15288) [Api][Admin] Product Attributes Management ([@NoResponseMate](https://github.com/NoResponseMate), [@GSadee](https://github.com/GSadee))
- [#15366](https://github.com/Sylius/Sylius/issues/15366) [Api][Attribute] Add types enum to product attribute schema ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15275](https://github.com/Sylius/Sylius/issues/15275) Optimize matching zones to a given address ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15373](https://github.com/Sylius/Sylius/issues/15373) [Api] Mark bulk delete scenarios as @no-api ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15362](https://github.com/Sylius/Sylius/issues/15362) Add OrderShipping Symfony Workflow configuration ([@TheMilek](https://github.com/TheMilek))
- [#15376](https://github.com/Sylius/Sylius/issues/15376) Component core deprecate order interface methods ([@Wojdylak](https://github.com/Wojdylak))
- [#15262](https://github.com/Sylius/Sylius/issues/15262) [Maintenance] Deprecate using `parentId` in TaxonSlugController ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15380](https://github.com/Sylius/Sylius/issues/15380) [ShippingBundle] Change deprecated Calendar class ([@Rafikooo](https://github.com/Rafikooo))
- [#15342](https://github.com/Sylius/Sylius/issues/15342) Add newline to align with other public method ([@stefandoorn](https://github.com/stefandoorn))
- [#15383](https://github.com/Sylius/Sylius/issues/15383) Fixes to order shipping workflow after review ([@TheMilek](https://github.com/TheMilek))
- [#15395](https://github.com/Sylius/Sylius/issues/15395) Fix failing phpspec scenario on Symfony 6.3.5 and above ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15397](https://github.com/Sylius/Sylius/issues/15397) Fix failing phpspec scenario on Symfony 6.3.5 and above ([@Wojdylak](https://github.com/Wojdylak))
- [#15406](https://github.com/Sylius/Sylius/issues/15406) Add Symfony workflow configuration for Shipment ([@TheMilek](https://github.com/TheMilek))
- [#15407](https://github.com/Sylius/Sylius/issues/15407) [API][Maintenance] Remove usage of deprecated IriConverter ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15422](https://github.com/Sylius/Sylius/issues/15422) [PaymentBundle] Rename void to unknown in sylius_payment state machine ([@Wojdylak](https://github.com/Wojdylak))
- [#15415](https://github.com/Sylius/Sylius/issues/15415) Add order payment workflow ([@Wojdylak](https://github.com/Wojdylak))
- [#15425](https://github.com/Sylius/Sylius/issues/15425) [PostgreSQL] Sylius installation fix ([@Rafikooo](https://github.com/Rafikooo))
- [#15423](https://github.com/Sylius/Sylius/issues/15423) [PaymentBundle] Add new state to sylius payment state machine ([@Wojdylak](https://github.com/Wojdylak))
- [#15411](https://github.com/Sylius/Sylius/issues/15411) [Workflow] Add payment state machine config ([@NoResponseMate](https://github.com/NoResponseMate), [@Wojdylak](https://github.com/Wojdylak))
- [#15408](https://github.com/Sylius/Sylius/issues/15408) [Documentation]Updated links that were redirecting to 404 ([@benbd5](https://github.com/benbd5))
- [#15427](https://github.com/Sylius/Sylius/issues/15427) [PostgreSQL] Sylius installation fix amend ([@Rafikooo](https://github.com/Rafikooo))
- [#13902](https://github.com/Sylius/Sylius/issues/13902) [API] Reset password : add validations to produce 422 instead of 500 status code ([@Prometee](https://github.com/Prometee), [@Wojdylak](https://github.com/Wojdylak))
- [#15429](https://github.com/Sylius/Sylius/issues/15429) [Maintenance][Core] Update payment state machine ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15399](https://github.com/Sylius/Sylius/issues/15399) [API][Admin] Managing products ([@GSadee](https://github.com/GSadee))
- [#15460](https://github.com/Sylius/Sylius/issues/15460) [API][Admin] Managing product variants ([@GSadee](https://github.com/GSadee))
- [#15457](https://github.com/Sylius/Sylius/issues/15457) [API] Add Customer resources ([@Wojdylak](https://github.com/Wojdylak))
- [#15466](https://github.com/Sylius/Sylius/issues/15466) Add symfony workflow configuration for order ([@TheMilek](https://github.com/TheMilek))
- [#15452](https://github.com/Sylius/Sylius/issues/15452) [API] Cover editing and deleting channels ([@TheMilek](https://github.com/TheMilek), [@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15501](https://github.com/Sylius/Sylius/issues/15501) [API] Automatically add a default translation to translatables ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15508](https://github.com/Sylius/Sylius/issues/15508) [ApiBundle] Validate locale field on translation object ([@Wojdylak](https://github.com/Wojdylak))
- [#15497](https://github.com/Sylius/Sylius/issues/15497) [UserBundle] Implement TTL validation for password reset tokens ([@Wojdylak](https://github.com/Wojdylak))
- [#15488](https://github.com/Sylius/Sylius/issues/15488) Making the verification and password reset token unqiue ([@mamazu](https://github.com/mamazu))
- [#15485](https://github.com/Sylius/Sylius/issues/15485) [FIX] Not using `payum/stripe` or `payum/paypal-express-checkout-nvp` ([@Prometee](https://github.com/Prometee))
- [#15480](https://github.com/Sylius/Sylius/issues/15480) [CS][DX] Refactor ([@github-actions](https://github.com/github-actions)[[@bot](https://github.com/bot)])
- [#15517](https://github.com/Sylius/Sylius/issues/15517) [API] Disallow removing the translation in default locale ([@GSadee](https://github.com/GSadee))
- [#15535](https://github.com/Sylius/Sylius/issues/15535) [ApiBundle] Unification of locale in translations ([@Wojdylak](https://github.com/Wojdylak))
- [#15504](https://github.com/Sylius/Sylius/issues/15504) [API][Admin] Managing taxon images ([@GSadee](https://github.com/GSadee))
- [#15540](https://github.com/Sylius/Sylius/issues/15540) Add note to UPGRADE file about introducing TaxonImageRepository ([@GSadee](https://github.com/GSadee))
- [#15546](https://github.com/Sylius/Sylius/issues/15546) [API][Admin] Revert changing taxon image file ([@GSadee](https://github.com/GSadee))
- [#15542](https://github.com/Sylius/Sylius/issues/15542) Update README.md ([@adrian-olebinski](https://github.com/adrian-olebinski))
- [#15524](https://github.com/Sylius/Sylius/issues/15524) [ApiBundle] Added remaining APIs for the Promotion resource. ([@Wojdylak](https://github.com/Wojdylak))
- [#15530](https://github.com/Sylius/Sylius/issues/15530) [API] Cover payment method management ([@TheMilek](https://github.com/TheMilek))
- [#15532](https://github.com/Sylius/Sylius/issues/15532) [API] Modifying placed order billing & shipping addresses ([@Rafikooo](https://github.com/Rafikooo))
- [#15552](https://github.com/Sylius/Sylius/issues/15552) Cover "Browsing order" scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15518](https://github.com/Sylius/Sylius/issues/15518) Prevent division by zero ([@cbastienbaron](https://github.com/cbastienbaron))
- [#15525](https://github.com/Sylius/Sylius/issues/15525) [Maintenance] Add more separation rules to arkitect ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15472](https://github.com/Sylius/Sylius/issues/15472) [API][Addressing] Enhance Country code validation ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15551](https://github.com/Sylius/Sylius/issues/15551) Resolve actions and rules configuration validation ([@Wojdylak](https://github.com/Wojdylak))
- [#15509](https://github.com/Sylius/Sylius/issues/15509) [API][Admin] Managing product images ([@GSadee](https://github.com/GSadee))
- [#15576](https://github.com/Sylius/Sylius/issues/15576) Resolve psalm issues ([@Wojdylak](https://github.com/Wojdylak))
- [#15566](https://github.com/Sylius/Sylius/issues/15566) Cover 'order filtration' scenarios in API ([@TheMilek](https://github.com/TheMilek))
- [#15579](https://github.com/Sylius/Sylius/issues/15579) [Behat] Unify the Currency Handling in Behat Scenarios ([@Rafikooo](https://github.com/Rafikooo))
- [#15568](https://github.com/Sylius/Sylius/issues/15568) [ApiBundle] Update validation message for command argument types. ([@Wojdylak](https://github.com/Wojdylak))
- [#15583](https://github.com/Sylius/Sylius/issues/15583) [Api][Test] Update promotion test response check ([@Wojdylak](https://github.com/Wojdylak))
- [#15539](https://github.com/Sylius/Sylius/issues/15539) [API][Admin] Promotion coupons management(CRUD) ([@NoResponseMate](https://github.com/NoResponseMate), [@Wojdylak](https://github.com/Wojdylak))
- [#15516](https://github.com/Sylius/Sylius/issues/15516) [Maintenance][Behat] Add suite isolation ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15595](https://github.com/Sylius/Sylius/issues/15595) Remove redundant denormalization check ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15558](https://github.com/Sylius/Sylius/issues/15558) [ECS] Add Code Checking In the Tests Directory and Implement Fixes For the New Code ([@Rafikooo](https://github.com/Rafikooo))
- [#15604](https://github.com/Sylius/Sylius/issues/15604) [Composer] Fix Symfony dependencies after upmerge ([@GSadee](https://github.com/GSadee))
- [#15553](https://github.com/Sylius/Sylius/issues/15553) Cover "Order details" scenarios in API ([@jakubtobiasz](https://github.com/jakubtobiasz), [@Wojdylak](https://github.com/Wojdylak))
- [#15605](https://github.com/Sylius/Sylius/issues/15605) [Workflow] Add catalog promotion state machine config ([@Wojdylak](https://github.com/Wojdylak))
- [#15601](https://github.com/Sylius/Sylius/issues/15601) [PHPStan] Baseline File Regeneration ([@Rafikooo](https://github.com/Rafikooo))
- [#15385](https://github.com/Sylius/Sylius/issues/15385) [Maintenance] Add more deprecations ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15561](https://github.com/Sylius/Sylius/issues/15561) [API]Cover generate promotion coupons ([@Wojdylak](https://github.com/Wojdylak))
- [#15549](https://github.com/Sylius/Sylius/issues/15549) Validate payment method's gateway configuration ([@TheMilek](https://github.com/TheMilek))
- [#15581](https://github.com/Sylius/Sylius/issues/15581) [API] Resolve update of translations ([@Wojdylak](https://github.com/Wojdylak))
- [#15611](https://github.com/Sylius/Sylius/issues/15611) Validate Paypal express checkout sandbox field type ([@TheMilek](https://github.com/TheMilek))
- [#15610](https://github.com/Sylius/Sylius/issues/15610) `JavaScriptTestHelper`: Interval Increase ([@Rafikooo](https://github.com/Rafikooo))
- [#15614](https://github.com/Sylius/Sylius/issues/15614) [Admin][UI] Fix csrf error breaking admin form ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15609](https://github.com/Sylius/Sylius/issues/15609) [Maintenance][API] Marking more inapplicable scenarios with no-api ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15620](https://github.com/Sylius/Sylius/issues/15620) Fix CI ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15615](https://github.com/Sylius/Sylius/issues/15615) Use serialized name when displaying an error about a wrong request field type ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15616](https://github.com/Sylius/Sylius/issues/15616) [API] Finish covering taxation scenarios ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15623](https://github.com/Sylius/Sylius/issues/15623) [API][Admin] Cover inventory ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15435](https://github.com/Sylius/Sylius/issues/15435) [Checkout] Prevent extra fields when login in on addressing page ([@Jibbarth](https://github.com/Jibbarth))
- [#14286](https://github.com/Sylius/Sylius/issues/14286) Prevent eager loading hundreds of countries ([@kayue](https://github.com/kayue))
- [#15627](https://github.com/Sylius/Sylius/issues/15627) Add an endpoint exposing customer's statistics ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15635](https://github.com/Sylius/Sylius/issues/15635) [API][Behat] covering tests for managing promotions ([@Wojdylak](https://github.com/Wojdylak))
- [#15636](https://github.com/Sylius/Sylius/issues/15636) [ECS] Ordered Types Fixer ([@Rafikooo](https://github.com/Rafikooo))
- [#15642](https://github.com/Sylius/Sylius/issues/15642) [Admin] Add official support submenu in admin panel ([@GSadee](https://github.com/GSadee))
- [#15628](https://github.com/Sylius/Sylius/issues/15628) [PromotionBundle] Update validation process of promotion actions/rules ([@Wojdylak](https://github.com/Wojdylak))
- [#15646](https://github.com/Sylius/Sylius/issues/15646) [API][Admin] Allow using float for amount in tax rates ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15630](https://github.com/Sylius/Sylius/issues/15630) Finish covering managing product-related resources ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15650](https://github.com/Sylius/Sylius/issues/15650) Update the example response of the Customer's statistics endpoint ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15658](https://github.com/Sylius/Sylius/issues/15658) Improve error handling while sending malformed amount value in the tax rate api resource update operation ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15640](https://github.com/Sylius/Sylius/issues/15640) [PromotionBundle] Deprecate PromotionCouponGeneratorInstructionInterface ([@Wojdylak](https://github.com/Wojdylak))
- [#15655](https://github.com/Sylius/Sylius/issues/15655) [Unit] `OrderPlacerTrait` Refactor ([@Rafikooo](https://github.com/Rafikooo))
- [#15637](https://github.com/Sylius/Sylius/issues/15637) [Behat] Implementation Improvements of the `ResponseCheckerInterface` ([@Rafikooo](https://github.com/Rafikooo))
- [#15662](https://github.com/Sylius/Sylius/issues/15662) Add running "Refactor" workflow daily ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15656](https://github.com/Sylius/Sylius/issues/15656) [AUTO] Updated translations from Crowdin (1.12) ([@SyliusBot](https://github.com/SyliusBot))
- [#15652](https://github.com/Sylius/Sylius/issues/15652) [UI] Improved Statistics Scenarios ([@Rafikooo](https://github.com/Rafikooo))
- [#15663](https://github.com/Sylius/Sylius/issues/15663) [ApiBundle][Address] Add address log entries operation ([@Wojdylak](https://github.com/Wojdylak))
- [#15632](https://github.com/Sylius/Sylius/issues/15632) Cover shipping method management ([@TheMilek](https://github.com/TheMilek))
- [#15639](https://github.com/Sylius/Sylius/issues/15639) [API][Admin] Finish covering product scenarios ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15660](https://github.com/Sylius/Sylius/issues/15660) [API] Finish covering managing orders ([@TheMilek](https://github.com/TheMilek))
- [#15657](https://github.com/Sylius/Sylius/issues/15657) [AUTO] Updated translations from Crowdin (1.13) ([@SyliusBot](https://github.com/SyliusBot))
- [#15617](https://github.com/Sylius/Sylius/issues/15617) Switch JS session Behat driver to the Symfony Panther ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15672](https://github.com/Sylius/Sylius/issues/15672) Typo cart-flow.rst ([@zairigimad](https://github.com/zairigimad))
- [#15664](https://github.com/Sylius/Sylius/issues/15664) Move validation groups parameters to appropriate bundle configs ([@TheMilek](https://github.com/TheMilek))
- [#13777](https://github.com/Sylius/Sylius/issues/13777) [Locale] Change language negotiation to RFC 4647 based ([@gseric](https://github.com/gseric))
- [#15687](https://github.com/Sylius/Sylius/issues/15687) Fix Typo fixtures.rst ([@zairigimad](https://github.com/zairigimad))
- [#15690](https://github.com/Sylius/Sylius/issues/15690) [Behat] Update test steps to use dynamic date ([@Wojdylak](https://github.com/Wojdylak))
- [#15695](https://github.com/Sylius/Sylius/issues/15695) [TestApi] Add new way of assert violations ([@Wojdylak](https://github.com/Wojdylak))
- [#15698](https://github.com/Sylius/Sylius/issues/15698) New year 2024! 🥳 ([@TheMilek](https://github.com/TheMilek))
- [#15705](https://github.com/Sylius/Sylius/issues/15705) [ApiBundle][ProductVariant] Unification of channelCode in channelPricing ([@Wojdylak](https://github.com/Wojdylak))
- [#15697](https://github.com/Sylius/Sylius/issues/15697) [Maintenance] Remove obsolete extended type method from form extensions ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15718](https://github.com/Sylius/Sylius/issues/15718) [Documentation] Extend the maintenance date of 1.12 and update future releases ([@GSadee](https://github.com/GSadee))
- [#15693](https://github.com/Sylius/Sylius/issues/15693) Allow to reset admin user password via CLI ([@Wojdylak](https://github.com/Wojdylak))
- [#15724](https://github.com/Sylius/Sylius/issues/15724) [API] Add validation of option values for the product variant ([@GSadee](https://github.com/GSadee))
- [#15728](https://github.com/Sylius/Sylius/issues/15728) [ApiBundle] Move LocaleIsUsedException into ApiBundle ([@Wojdylak](https://github.com/Wojdylak))
- [#15729](https://github.com/Sylius/Sylius/issues/15729) Extract StateMachine abstraction into its own package ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15712](https://github.com/Sylius/Sylius/issues/15712) Refactor resending order confirmation email and cover it in API ([@TheMilek](https://github.com/TheMilek))
- [#15707](https://github.com/Sylius/Sylius/issues/15707) [ApiBundle][Admin] Implement Shop User Removal and Password Change ([@Wojdylak](https://github.com/Wojdylak))
- [#15739](https://github.com/Sylius/Sylius/issues/15739) Fix ZoneRepository BC-Break ([@Rafikooo](https://github.com/Rafikooo))
- [#15598](https://github.com/Sylius/Sylius/issues/15598) [API] Statistics ([@Rafikooo](https://github.com/Rafikooo), [@TheMilek](https://github.com/TheMilek), [@NoResponseMate](https://github.com/NoResponseMate))
- [#15730](https://github.com/Sylius/Sylius/issues/15730) Organization of ConsoleCommands/Messages ([@Wojdylak](https://github.com/Wojdylak))
- [#15715](https://github.com/Sylius/Sylius/issues/15715) Refactor resending shipment confirmation email and cover it in API ([@TheMilek](https://github.com/TheMilek))
- [#15751](https://github.com/Sylius/Sylius/issues/15751) Adjust some wording in UPGRADE guide ([@stefandoorn](https://github.com/stefandoorn))
- [#15754](https://github.com/Sylius/Sylius/issues/15754) Update the branch-aliases and inter-dependencies versions ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15740](https://github.com/Sylius/Sylius/issues/15740) Improve setup command ([@TheMilek](https://github.com/TheMilek))
- [#15761](https://github.com/Sylius/Sylius/issues/15761) [Admin] Add Sylius certification to menu ([@Wojdylak](https://github.com/Wojdylak))
- [#15755](https://github.com/Sylius/Sylius/issues/15755) [ApiBundle] Refactor commands' constructors ([@Wojdylak](https://github.com/Wojdylak))
- [#15749](https://github.com/Sylius/Sylius/issues/15749) [AUTO] Updated translations from Crowdin (1.12)
- [#15750](https://github.com/Sylius/Sylius/issues/15750) [AUTO] Updated translations from Crowdin (1.13)
- [#15768](https://github.com/Sylius/Sylius/issues/15768) [Fix] Invalid RemoveShopUserHandlerSpec namespace ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15746](https://github.com/Sylius/Sylius/issues/15746) Add builds checking whether the frontend can be built with all supported nodejs versions ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15771](https://github.com/Sylius/Sylius/issues/15771) Add default locale paramter to core ([@TheMilek](https://github.com/TheMilek))
- [#15775](https://github.com/Sylius/Sylius/issues/15775) [Maintenance][API] Normalize command missing fields' names ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15777](https://github.com/Sylius/Sylius/issues/15777) Bump the @sylius-ui/frontend version ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15765](https://github.com/Sylius/Sylius/issues/15765) [Maintenance][Statistics] Bit of an overhaul ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15708](https://github.com/Sylius/Sylius/issues/15708) [Promotion] Switch catalog promotion validation from custom solution to symfony ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15770](https://github.com/Sylius/Sylius/issues/15770) [API] Split read serialization group ([@TheMilek](https://github.com/TheMilek))
- [#15780](https://github.com/Sylius/Sylius/issues/15780) [API] Add BC layer for transition from :read to :index and :show serialization groups ([@TheMilek](https://github.com/TheMilek))
- [#15738](https://github.com/Sylius/Sylius/issues/15738) Use the new State Machine abstraction ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15796](https://github.com/Sylius/Sylius/issues/15796) Update codeowners ([@jakubtobiasz](https://github.com/jakubtobiasz))
- [#15798](https://github.com/Sylius/Sylius/issues/15798) Move CartQuantityRuleChecker to CoreBundle ([@Wojdylak](https://github.com/Wojdylak))
- [#15802](https://github.com/Sylius/Sylius/issues/15802) [Maintenance] Cleanup ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15804](https://github.com/Sylius/Sylius/issues/15804) [StateMachineAbstraction] Add missing LICENSE and README files ([@GSadee](https://github.com/GSadee))
- [#15805](https://github.com/Sylius/Sylius/issues/15805) Update the license years for the last time ([@GSadee](https://github.com/GSadee))
- [#15806](https://github.com/Sylius/Sylius/issues/15806) [Documentation] Fix table of supported versions ([@GSadee](https://github.com/GSadee))
- [#15774](https://github.com/Sylius/Sylius/issues/15774) [Emails] Move email managers from Admin and Shop bundles to CoreBundle ([@GSadee](https://github.com/GSadee))
- [#15799](https://github.com/Sylius/Sylius/issues/15799) Move ItemTotalRuleChecker to CoreBundle ([@Wojdylak](https://github.com/Wojdylak))
- [#15735](https://github.com/Sylius/Sylius/issues/15735) Validate resending order confirmation email ([@TheMilek](https://github.com/TheMilek))
- [#15808](https://github.com/Sylius/Sylius/issues/15808) [Maintenance] Update .gitattributes ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15809](https://github.com/Sylius/Sylius/issues/15809) [Maintenance][Behat] Autoload calendar contexts into container ([@NoResponseMate](https://github.com/NoResponseMate))
- [#15815](https://github.com/Sylius/Sylius/issues/15815) Update the branch-aliases ([@Wojdylak](https://github.com/Wojdylak))
- [#15757](https://github.com/Sylius/Sylius/issues/15757) Missing typehint on processDistributionWithMinimumPrice ([@cbastienbaron](https://github.com/cbastienbaron))
- [#15814](https://github.com/Sylius/Sylius/issues/15814) [AUTO] Updated translations from Crowdin (1.13)

View file

@ -3,58 +3,17 @@
This document explains why certain conflicts were added to `composer.json` and
references related issues.
- `doctrine/doctrine-bundle:2.3.0`:
This version makes Gedmo Doctrine Extensions fail (tree and position behaviour mostly).
References: https://github.com/doctrine/DoctrineBundle/issues/1305
- `jms/serializer-bundle:4.1.0`:
This version contains service with a wrong constructor arguments:
`Invalid definition for service ".container.private.profiler": argument 4 of "JMS\SerializerBundle\Debug\DataCollector::__construct()" accepts "JMS\SerializerBundle\Debug\TraceableDriver", "JMS\SerializerBundle\Debug\TraceableMetadataFactory" passed.`
References: https://github.com/schmittjoh/JMSSerializerBundle/issues/902
- `symfony/dependency-injection:5.4.5`:
This version is causing a problem with mink session:
`InvalidArgumentException: Specify session name to get in vendor/friends-of-behat/mink/src/Mink.php:198`,
- `symfony/framework-bundle:5.4.5`:
This version is causing a problem with returning null as token from `Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage`
which leads to wrong solving path prefix by `Sylius\Bundle\ApiBundle\Provider\PathPrefixProvider` in API scenarios
- `api-platform/core:2.7.0`:
The FQCN of `ApiPlatform\Core\Metadata\Resource\ResourceNameCollection` has changed to:
`ApiPlatform\Metadata\Resource\ResourceNameCollection` and due to this fact
`Sylius\Bundle\ApiBundle\Swagger\AcceptLanguageHeaderDocumentationNormalizer`
references this class throws an exception
`Class "ApiPlatform\Core\Metadata\Resource\ResourceNameCollection" not found`
- `doctrine/migrations:3.5.3`:
This version is causing a problem with migrations and results in throwing a `Doctrine\Migrations\Exception\MetadataStorageError` exception e.g. when executing `sylius:install` command.
References: https://github.com/doctrine/migrations/issues/1302
- `lexik/jwt-authentication-bundle: ^2.18`
After bumping to this version ApiBundle starts failing due to requesting a non-existing `api_platform.openapi.factory.legacy` service.
As we are not using this service across the ApiBundle we added this conflict to unlock the builds, until we investigate the problem.
- `symfony/framework-bundle:6.2.8`:
This version is missing the service alias `validator.expression`
which causes ValidatorException exception to be thrown when using `Expression` constraint.
- `doctrine/orm:>= 2.16.0`
This version makes Sylius Fixtures loading fail on the product review fixtures.
References: https://github.com/doctrine/orm/issues/10869
- `symfony/validator:5.4.25 || 6.2.12 || 6.3.1`
- `symfony/validator:5.4.25`
This version introduced a bug, causing validation constraints to not work.
References: https://github.com/symfony/symfony/issues/50780

View file

@ -1,6 +1,6 @@
<h1 align="center">
<a href="https://sylius.com/github-readme/link/" target="_blank">
<img src="https://sylius.com/assets/github-readme.png?sylius-days" />
<img src="https://sylius.com/assets/github-readme.png?course" />
</a>
</h1>

View file

@ -92,7 +92,9 @@ class RoboFile extends Tasks
$task->exec('rm spec/Security/UserPasswordEncoderSpec.php');
}
$task->exec('vendor/bin/phpspec run --ansi --no-interaction -f dot');
if (file_exists(sprintf('%s/phpspec.yml', $packagePath)) || file_exists(sprintf('%s/phpspec.yml.dist', $packagePath)) || file_exists(sprintf('%s/phpspec.yaml', $packagePath))) {
$task->exec('vendor/bin/phpspec run --ansi --no-interaction -f dot');
}
if (file_exists(sprintf('%s/phpunit.xml', $packagePath)) || file_exists(sprintf('%s/phpunit.xml.dist', $packagePath))) {
$task->exec('vendor/bin/phpunit --colors=always');

541
UPGRADE-1.13.md Normal file
View file

@ -0,0 +1,541 @@
# UPGRADE FROM `v1.12.X` TO `v1.13.0`
## Preconditions
### PHP 8.1 support
Sylius 1.13 comes with a bump of minimum PHP version to 8.1. We strongly advice to make upgrade process step by step,
so it is highly recommended updating your PHP version being still on Sylius 1.12. After ensuring, that previous step succeed,
you may move forward to the Sylius 1.13 update.
### Symfony support
In Sylius 1.13, the minimum supported version of Symfony 6 has been bumped up to 6.4. Sylius 1.13 supports both long-term
supported Symfony versions: 5.4 and 6.4.
## Main update
1. Starting with Sylius `1.13` we provided a possibility to use the Symfony Workflow as your State Machine. To allow a smooth transition
we created a new package called `sylius/state-machine-abstraction`,
which provides a configurable abstraction,
allowing you to define which adapter should be used (Winzou State Machine or Symfony Workflow) per graph.
Starting with Sylius `1.13` we configure all existing Sylius' graphs to use the Symfony Workflow.
At the same time, all other graphs are using Winzou State Machine as a default state machine,
and must be configured manually to use the Symfony Workflow.
Configuration:
```yaml
sylius_state_machine_abstraction:
graphs_to_adapters_mapping:
<graph_name>: <adapter_name>
# e.g.
sylius_order_checkout: symfony_workflow # available adapters: symfony_workflow, winzou_state_machine
# we can also can the default adapter
default_adapter: symfony_workflow # winzou_state_machine is a default value here
```
> **Note!** Starting with Sylius `2.0` the Symfony Workflow will be the default state machine for all graphs.
1. A new parameter has been added to specify the validation groups for given gateway factory.
If you have any custom validation groups for your factory, you need to add them to your `config/packages/_sylius.yaml` file.
Also, if you have your own gateway factory and want to add your validation groups you can add another entry to the `validation_groups` configuration node.
It is handled by `GatewayConfigGroupsGenerator` and it resolves the groups based on the passed factory name.
```yaml
sylius_payum:
gateway_config:
validation_groups:
paypal_express_checkout:
- 'sylius'
- 'sylius_paypal_express_checkout'
stripe_checkout:
- 'sylius'
- 'sylius_stripe_checkout'
your_gateway:
- 'sylius'
- 'your_custom_validation_group'
```
1. There have been a naw parameters added to specify the validation groups for given shipping method rule and calculator.
If you have any custom validation groups for your calculator or rules, you need to add them to your `config/packages/_sylius.yaml` file.
Also, if you have your own shipping method rule or calculator and want to add your validation groups you can add another key to the `validation_groups` parameter.
```yaml
sylius_shipping:
shipping_method_rule:
validation_groups:
total_weight_greater_than_or_equal:
- 'sylius'
- 'sylius_shipping_method_rule_total_weight'
order_total_greater_than_or_equal:
- 'sylius'
- 'sylius_shipping_method_rule_order_total'
your_shipping_method_rule:
- 'sylius'
- 'your_custom_validation_group'
shipping_method_calculator:
validation_groups:
flat_rate:
- 'sylius'
- 'sylius_shipping_method_calculator_rate'
per_unit_rate:
- 'sylius'
- 'sylius_shipping_method_calculator_rate'
your_shipping_method_calculator:
- 'sylius'
- 'your_custom_validation_group'
```
1. Class `Sylius\Component\Core\Promotion\Updater\Rule\TotalOfItemsFromTaxonRuleUpdater` has been deprecated, as it is no more used.
1. Class `Sylius\Component\Core\Promotion\Updater\Rule\ContainsProductRuleUpdater` has been deprecated, as it is no more used.
1. Class `Sylius\Bundle\AdminBundle\EmailManager\OrderEmailManager` and its interface `Sylius\Bundle\AdminBundle\EmailManager\OrderEmailManagerInterface`
have been deprecated, use `Sylius\Bundle\CoreBundle\Mailer\OrderEmailManager` and `Sylius\Bundle\CoreBundle\Mailer\OrderEmailManagerInterface` instead.
1. Class `Sylius\Bundle\AdminBundle\EmailManager\ShipmentEmailManager` and its interface `Sylius\Bundle\AdminBundle\EmailManager\ShipmentEmailManagerInterface`
have been deprecated, use `Sylius\Bundle\CoreBundle\Mailer\ShipmentEmailManager` and `Sylius\Bundle\CoreBundle\Mailer\ShipmentEmailManagerInterface` instead.
1. Class `Sylius\Bundle\ShopBundle\EmailManager\ContactEmailManager` and its interface `Sylius\Bundle\ShopBundle\EmailManager\ContactEmailManagerInterface`
have been deprecated, use `Sylius\Bundle\CoreBundle\Mailer\ContactEmailManager` and `Sylius\Bundle\CoreBundle\Mailer\ContactEmailManagerInterface` instead.
1. Class `Sylius\Bundle\ShopBundle\EmailManager\OrderEmailManager` and its interface `Sylius\Bundle\ShopBundle\EmailManager\OrderEmailManagerInterface`
have been deprecated, use `Sylius\Bundle\CoreBundle\Mailer\OrderEmailManager` and `Sylius\Bundle\CoreBundle\Mailer\OrderEmailManagerInterface` instead.
1. Class `Sylius\Bundle\ProductBundle\Form\Type\ProductOptionChoiceType` has been deprecated.
Use `Sylius\Bundle\ProductBundle\Form\Type\ProductOptionAutocompleteType` instead.
1. Using `parentId` query parameter to generate slug in `Sylius\Bundle\TaxonomyBundle\Controller\TaxonSlugController` has been deprecated.
Use the `parentCode` query parameter instead.
1. Starting with Sylius 1.13, the `SyliusPriceHistoryPlugin` is included.
If you are currently using the plugin in your project, we recommend following the upgrade guide located [here](UPGRADE-FROM-1.12-WITH-PRICE-HISTORY-PLUGIN-TO-1.13.md).
1. The `Sylius\Bundle\CoreBundle\CatalogPromotion\Command\RemoveInactiveCatalogPromotion` command and its handler
`Sylius\Bundle\CoreBundle\CatalogPromotion\CommandHandler\RemoveInactiveCatalogPromotionHandler` have been deprecated.
Use `Sylius\Bundle\CoreBundle\CatalogPromotion\Command\RemoveCatalogPromotion` command instead.
1. Passing `Symfony\Component\Messenger\MessageBusInterface` to `Sylius\Bundle\CoreBundle\CatalogPromotion\Processor\CatalogPromotionRemovalProcessor`
as a second and third argument is deprecated.
1. Passing `Sylius\Bundle\AdminBundle\EmailManager\OrderEmailManagerInterface` to `Sylius\Bundle\AdminBundle\Action\ResendOrderConfirmationEmailAction` as a second argument is deprecated, use `Sylius\Bundle\CoreBundle\MessageDispatcher\ResendOrderConfirmationEmailDispatcherInterface` instead.
1. The name of the second argument of `Sylius\Bundle\AdminBundle\Action\ResendOrderConfirmationEmailAction` is deprecated and will be renamed to `$resendOrderConfirmationEmailDispatcher`.
1. Passing `Sylius\Bundle\AdminBundle\EmailManager\ShipmentEmailManagerInterface` to `Sylius\Bundle\AdminBundle\Action\ResendShipmentConfirmationEmailAction` as a second argument is deprecated, use `Sylius\Bundle\CoreBundle\MessageDispatcher\ResendShipmentConfirmationEmailDispatcherInterface` instead.
1. The name of the second argument of `Sylius\Bundle\AdminBundle\Action\ResendShipmentConfirmationEmailAction` is deprecated and will be renamed to `$resendShipmentConfirmationEmailDispatcher`.
1. Passing `Sylius\Bundle\AdminBundle\EmailManager\ShipmentEmailManagerInterface` to `Sylius\Bundle\AdminBundle\EventListener\ShipmentShipListener` as a first argument is deprecated, use `Sylius\Bundle\CoreBundle\Mailer\ShipmentEmailManagerInterface` instead.
1. Passing `Sylius\Bundle\ShopBundle\EmailManager\OrderEmailManagerInterface` to `Sylius\Bundle\ShopBundle\EventListener\OrderCompleteListener` as a first argument is deprecated, use `Sylius\Bundle\CoreBundle\Mailer\OrderEmailManagerInterface` instead.
1. Passing `Sylius\Bundle\ShopBundle\EmailManager\ContactEmailManagerInterface` to `Sylius\Bundle\ShopBundle\Controller\ContactController` as last argument is deprecated, use `Sylius\Bundle\CoreBundle\Mailer\ContactEmailManagerInterface` instead.
1. Not passing `Sylius\Bundle\CoreBundle\CatalogPromotion\Announcer\CatalogPromotionRemovalAnnouncerInterface` to `Sylius\Bundle\CoreBundle\CatalogPromotion\Processor\CatalogPromotionRemovalProcessor`
as a second argument is deprecated.
1. Not passing `Doctrine\Persistence\ObjectManager` to `Sylius\Component\Core\Updater\UnpaidOrdersStateUpdater`
as a fifth argument is deprecated.
1. Not passing `Symfony\Component\Filesystem\Filesystem` as fourth argument and parameters file path as fifth to `Sylius\Bundle\CoreBundle\Installer\Setup\LocaleSetup` is deprecated and will be prohibited in Sylius 2.0.
1. To ease customization we've introduced attributes for some services in `1.13`:
- `Sylius\Bundle\OrderBundle\Attribute\AsCartContext` for cart contexts
- `Sylius\Bundle\OrderBundle\Attribute\AsOrderProcessor` for order processors
- `Sylius\Bundle\ProductBundle\Attribute\AsProductVariantResolver` for product variant resolvers
By default, Sylius still configures them using interfaces, but this way you cannot define a priority.
If you want to define a priority, you need to set the following configuration in your `_sylius.yaml` file:
```yaml
sylius_core:
autoconfigure_with_attributes: true
```
and use one of the new attributes accordingly to the type of your class, e.g.:
```php
<?php
declare(strict_types=1);
namespace App\OrderProcessor;
use Sylius\Bundle\OrderBundle\Attribute\AsOrderProcessor;
use Sylius\Component\Order\Model\OrderInterface;
use Sylius\Component\Order\Processor\OrderProcessorInterface;
#[AsOrderProcessor(/*priority: 10*/)] //priority is optional
final class OrderProcessorWithAttributeStub implements OrderProcessorInterface
{
public function process(OrderInterface $order): void
{
}
}
```
1. Not passing `Sylius\Component\Core\Checker\ProductVariantLowestPriceDisplayCheckerInterface`
to `Sylius\Component\Core\Calculator\ProductVariantPriceCalculator`
as a first argument is deprecated.
1. Not passing an instance of `Symfony\Component\PropertyAccess\PropertyAccessorInterface`
to `Sylius\Bundle\CoreBundle\Validator\Constraints\HasEnabledEntityValidator`
as the second argument is deprecated.
1. Not passing an instance of `Sylius\Component\Core\Payment\Remover\OrderPaymentsRemoverInterface`
and a collection of unprocessable order states to `Sylius\Component\Core\OrderProcessing\OrderPaymentProcessor`
as the third and fourth arguments respectively is deprecated.
1. Not passing an instance of `Sylius\Component\Core\Distributor\ProportionalIntegerDistributorInterface`
to `Sylius\Component\Core\Taxation\Applicator\OrderItemsTaxesApplicator` and to `Sylius\Component\Core\Taxation\Applicator\OrderItemUnitsTaxesApplicator`
as the last argument is deprecated.
1. Class `\Sylius\Bundle\ShopBundle\Calculator\OrderItemsSubtotalCalculator` has been deprecated. Order items subtotal calculation
is now available on the Order model `\Sylius\Component\Core\Model\Order::getItemsSubtotal`.
1. The way of getting variants prices based on options has been changed,
as such the following services were deprecated, please use their new counterpart.
* instead of `Sylius\Component\Core\Provider\ProductVariantsPricesProviderInterface` use `Sylius\Component\Core\Provider\ProductVariantMap\ProductVariantsMapProviderInterface`
* instead of `Sylius\Component\Core\Provider\ProductVariantsPricesProvider` use `Sylius\Component\Core\Provider\ProductVariantMap\ProductVariantsPricesMapProvider`
* instead of `Sylius\Bundle\CoreBundle\Templating\Helper\ProductVariantsPricesHelper` use `Sylius\Component\Core\Provider\ProductVariantMap\ProductVariantsPricesMapProvider`
* instead of `Sylius\Bundle\CoreBundle\Twig\ProductVariantsPricesExtension` use `Sylius\Bundle\CoreBundle\Twig\ProductVariantsMapExtension`
Subsequently, the `sylius_product_variant_prices` twig function is deprecated, use `sylius_product_variants_map` instead.
To add more data per variant create a service implementing the `Sylius\Component\Core\Provider\ProductVariantMap\ProductVariantMapProviderInterface` and tag it with `sylius.product_variant_data_map_provider`.
1. Using Guzzle 6 has been deprecated in favor of Symfony HTTP Client. If you want to still use Guzzle 6 or Guzzle 7,
you need to install `composer require php-http/guzzle6-adapter` or `composer require php-http/guzzle7-adapter`
depending on your Guzzle version.
Subsequently, you need to register the adapter as a `Psr\Http\Client\ClientInterface` service as the following:
```yaml
services:
Psr\Http\Client\ClientInterface:
class: Http\Adapter\Guzzle7\Client # for Guzzle 6 use Http\Adapter\Guzzle6\Client instead
```
1. The constructor of `Sylius\Bundle\AdminBundle\Controller\NotificationController` has been changed:
```diff
public function __construct(
- private ClientInterface $client,
- private MessageFactory $messageFactory,
+ private ClientInterface|DeprecatedClientInterface $client,
+ private RequestFactoryInterface|MessageFactory $requestFactory,
private string $hubUri,
private string $environment,
+ private ?StreamFactoryInterface $streamFactory = null,
) {
...
}
```
1. The `sylius.http_message_factory` service has been deprecated. Use `Psr\Http\Message\RequestFactoryInterface` instead.
1. The `sylius.http_client` has become an alias to `psr18.http_client` service.
1. The `sylius.payum.http_client` has become a service ID of newly created `Sylius\Bundle\PayumBundle\HttpClient\HttpClient`.
1. Validation translation key `sylius.review.rating.range` has been replaced by `sylius.review.rating.not_in_range` in all places used by Sylius. The `sylius.review.rating.range` has been left for backward compatibility and will be removed in Sylius 2.0.
1. The `payum/payum` package has been replaced by concrete packages like `payum/core`, `payum/offline` or `payum/paypal-express-checkout-nvp`. If you need any other component so far provided by `payum/payum` package, you need to install it explicitly.
1. PostgreSQL migration support has been introduced. If you are using PostgreSQL, we assume that you have already created a database schema in some way.
All you need to do is run migrations, which will mark all migrations created before Sylius 1.13 as executed.
1. Not passing an `$entityManager` and passing a `$doctrineRegistry` to `Sylius\Bundle\CoreBundle\Installer\Provider\DatabaseSetupCommandsProvider` constructor is deprecated and will be prohibited in Sylius 2.0.
1. Product variants resolving has been refactored for better extendability.
The tag `sylius.product_variant_resolver.default` has been removed as it was never used.
All internal usages of service `sylius.product_variant_resolver.default` have been switched to `Sylius\Component\Product\Resolver\ProductVariantResolverInterface`, if you have been using the
`sylius.product_variant_resolver.default` service apply this change accordingly.
1. Due to optimizations of the Order's grid the `Sylius\Component\Core\Repository\OrderRepositoryInterface::createSearchListQueryBuilder` method bas been deprecated in both the interface and the class, and replaced by `Sylius\Component\Core\Repository\OrderRepositoryInterface::createCriteriaAwareSearchListQueryBuilder`.
Also `Sylius\Component\Core\Repository\OrderRepositoryInterface::createByCustomerIdQueryBuilder` has been deprecated in both the interface and the class, and replaced by `Sylius\Component\Core\Repository\OrderRepositoryInterface::createByCustomerIdCriteriaAwareQueryBuilder` for the same reason. Both changes affect
`sylius_admin_order` and `sylius_admin_customer_order` grids configuration.
1. We have explicitly added relationships between product and reviews and between product and attributes in XML mappings.
Because of that, the subscribers `Sylius\Bundle\AttributeBundle\Doctrine\ORM\Subscriber\LoadMetadataSubscriber`
and `Sylius\Bundle\ReviewBundle\Doctrine\ORM\Subscriber\LoadMetadataSubscriber` have changed so that it does not add
a relationship if one already exists. If you have overwritten or decorated it, there may be a need to update it.
1. Passing an instance of `Sylius\Component\Resource\Translation\Provider\TranslationLocaleProviderInterface` as the first argument
to `Sylius\Bundle\AttributeBundle\Form\Type\AttributeType\Configuration\SelectAttributeChoicesCollectionType` has been deprecated.
1. The `sylius_admin_ajax_taxon_move` route has been deprecated. If you're relaying on it, consider migrating to new
`sylius_admin_ajax_taxon_move_up` and `sylius_admin_ajax_taxon_move_down` routes.
1. Not passing a `$fileLocator` to `Sylius\Bundle\CoreBundle\Fixture\Factory\ProductExampleFactory` constructor is deprecated and will be prohibited in Sylius 2.0.
1. Interface `Sylius\Bundle\ShopBundle\Calculator\OrderItemsSubtotalCalculatorInterface` and class `Sylius\Bundle\ShopBundle\Twig\OrderItemsSubtotalExtension` responsible for the `sylius_order_items_subtotal` twig function have been deprecated and will be removed in Sylius 2.0.
Use the `::getItemsSubtotal()` method from the `Order` class instead.
1. The `Sylius\Bundle\CoreBundle\Fixture\Factory\PaymentFixture` has been deprecated. Use `Sylius\Bundle\CoreBundle\Fixture\PaymentFixture` instead.
1. Not passing a `$router` to `Sylius\Bundle\AdminBundle\Controller\ImpersonateUserController` as the fourth argument is deprecated and will be prohibited in Sylius 2.0.
1. The `Sylius\Bundle\CoreBundle\Provider\SessionProvider` has been deprecated and will be removed in Sylius 2.0.
1. Interface `Sylius\Component\Core\Promotion\Updater\Rule\ProductAwareRuleUpdaterInterface` has been deprecated and will be removed in Sylius 2.0.
1. Both `getCreatedByGuest` and `setCreatedByGuest` methods were deprecated on `\Sylius\Component\Core\Model\OrderInterface`.
Please use `isCreatedByGuest` instead of the first one. The latter is a part of the `setCustomerWithAuthorization` logic
and should be used only this way.
1. The `Sylius\Bundle\ShippingBundle\Provider\Calendar` and `Sylius\Bundle\ShippingBundle\Provider\DateTimeProvider` have been deprecated and will be removed in Sylius 2.0. Use `Symfony\Component\Clock\Clock` instead. Note: this class is available since Symfony 6.2.
1. In the `sylius_payment` state machine of `PaymentBundle`, there has been a change in the state name:
- State name change:
- From: `void`
- To: `unknown`
1. In the `sylius_payment` state machine of `PaymentBundle`, a new state `authorized` has been introduced, along with a new transition:
- Transition `authorize`:
- From states: [`new`, `processing`]
- To state: `authorized`
Due to that the following transitions have been updated:
- Transition `complete`:
- From states: [`new`, `processing`, `authorized`]
- To state: `completed`
- Transition `fail`:
- From states: [`new`, `processing`, `authorized`]
- To state: `failed`
- Transition `cancel`:
- From states: [`new`, `processing`, `authorized`]
- To state: `cancelled`
- Transition `void`:
- From states: [`new`, `processing`, `authorized`]
- To state: `unknown`
1. The `sylius_payment` state machine of `CoreBundle` has been updated to allow failing an authorized payment:
```diff
fail:
- from: [new, processing]
+ from: [new, processing, authorized]
to: failed
```
1. Change in the `Sylius\Bundle\CoreBundle\Fixture\Factory\PromotionExampleFactory` constructor:
Added the `$localeRepository` argument to the constructor of the `PromotionExampleFactory` class. Not passing an instance of `RepositoryInterface` for the `locale` entity repository in `$localeRepository` was marked as deprecated and will be prohibited in Sylius 2.0.
1. The `Regex` constraint has been removed from `Sylius\Component\Addressing\Model\Country` in favour of the `Country` constraint.
Due to that, it's translation message `sylius.country.code.regex` was also removed.
1. The `redirectToCartSummary` protected method of `Sylius\Bundle\OrderBundle\Controller\OrderController` has been deprecated as it was never used and will be removed in Sylius 2.0.
1. Interface `Sylius\Component\Promotion\Generator\PromotionCouponGeneratorInstructionInterface` has been refactored and is now deprecated. It now extends a new interface `Sylius\Component\Promotion\Generator\PromotionCouponGeneratorInstructionReadInterface`, which contains only getter methods.
- If your services or custom implementations previously relied on `PromotionCouponGeneratorInstructionInterface` for read operations, you should now use `PromotionCouponGeneratorInstructionReadInterface` for better clarity and separation of concerns.
- This change is backward compatible as long as your implementations or services were using only the getter methods from `PromotionCouponGeneratorInstructionInterface`. However, if you also utilized setter methods, you should continue using `PromotionCouponGeneratorInstructionInterface`.
1. A new parameter has been added to specify the validation groups for a given promotion action.
If you have any custom validation groups for your promotion action, you need to add them to your `config/packages/_sylius.yaml` file.
Additionally, if you have your own promotion action and want to add your validation groups, you can add another key to the `promotion_action.validation_groups` parameter.
This is handled by `Sylius\Bundle\PromotionBundle\Validator\PromotionActionGroupValidator` and it resolves the groups based on the type of the passed promotion action.
```yaml
sylius_promotion:
promotion_action:
validation_groups:
order_percentage_discount:
- 'sylius'
- 'sylius_promotion_action_order_percentage_discount'
shipping_percentage_discount:
- 'sylius'
- 'sylius_promotion_action_shipping_percentage_discount'
your_promotion_action:
- 'sylius'
- 'your_custom_validation_group'
```
Along with this update, constraints have been removed from specific action form types. The affected form types include:
- `Sylius\Bundle\PromotionBundle\Form\Type\Action\FixedDiscountConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\Action\PercentageDiscountConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\Action\UnitFixedDiscountConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\Action\UnitPercentageDiscountConfigurationType`
The constraints previously defined in these forms are now in `src/Sylius/Bundle/CoreBundle/Resources/config/validation/PromotionAction.xml` and managed via the new validation groups parameters in the configuration.
1. A new parameter has been added to specify the validation groups for a given promotion rule.
If you have any custom validation groups for your promotion rule, you need to add them to your `config/packages/_sylius.yaml` file.
Additionally, if you have your own promotion rule and want to add your validation groups, you can add another key to the `promotion_rule.validation_groups` parameter.
This is handled by `Sylius\Bundle\PromotionBundle\Validator\PromotionRuleGroupValidator` and it resolves the groups based on the type of the passed promotion rule.
```yaml
sylius_promotion:
promotion_rule:
validation_groups:
cart_quantity:
- 'sylius'
- 'sylius_promotion_rule_cart_quantity'
customer_group:
- 'sylius'
- 'sylius_promotion_rule_customer_group'
your_promotion_rule:
- 'sylius'
- 'your_custom_validation_group'
```
Along with this update, constraints have been removed from specific rule form types. The affected form types include:
- `Sylius\Bundle\CoreBundle\Form\Type\Promotion\Rule\ContainsProductConfigurationType`
- `Sylius\Bundle\CoreBundle\Form\Type\Promotion\Rule\NthOrderConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\Rule\CartQuantityConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\Rule\ItemTotalConfigurationType`
The constraints previously defined in these forms are now in `src/Sylius/Bundle/CoreBundle/Resources/config/validation/PromotionRule.xml` and managed via the new validation groups parameters in the configuration.
1. The `Sylius\Component\Addressing\Repository\ZoneRepositoryInterface` and
`Sylius\Bundle\AddressingBundle\Repository\ZoneRepository` were added.
If you created a custom `Zone` repository, you should update it to extend the `Sylius\Bundle\AddressingBundle\Repository\ZoneRepository`
1. The constructor of `Sylius\Component\Addressing\Matcher\ZoneMatcher` has been changed:
```php
use Sylius\Component\Addressing\Repository\ZoneRepositoryInterface;
use Sylius\Component\Resource\Repository\RepositoryInterface;
public function __construct(
- private RepositoryInterface $zoneRepository,
+ private RepositoryInterface|ZoneRepositoryInterface $zoneRepository,
)
```
1. Moved classes from `Command` to `Console\Command`. The `Command` namespace is deprecated for console command classes and will be removed in Sylius 2.0.
List of affected classes:
- `\Sylius\Bundle\OrderBundle\Command\RemoveExpiredCartsCommand` to `\Sylius\Bundle\OrderBundle\Console\Command\RemoveExpiredCartsCommand`
- `\Sylius\Bundle\PromotionBundle\Command\GenerateCouponsCommand` to `\Sylius\Bundle\PromotionBundle\Console\Command\GenerateCouponsCommand`
- `\Sylius\Bundle\UiBundle\Command\DebugTemplateEventCommand` to `\Sylius\Bundle\UiBundle\Console\Command\DebugTemplateEventCommand`
- `\Sylius\Bundle\UserBundle\Command\AbstractRoleCommand` to `\Sylius\Bundle\UserBundle\Console\Command\AbstractRoleCommand`
- `\Sylius\Bundle\UserBundle\Command\DemoteUserCommand` to `\Sylius\Bundle\UserBundle\Console\Command\DemoteUserCommand`
- `\Sylius\Bundle\UserBundle\Command\PromoteUserCommand` to `\Sylius\Bundle\UserBundle\Console\Command\PromoteUserCommand`
- `\Sylius\Bundle\CoreBundle\Command\Model\PluginInfo` to `\Sylius\Bundle\CoreBundle\Console\Command\Model\PluginInfo`
- `\Sylius\Bundle\CoreBundle\Command\AbstractInstallCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\AbstractInstallCommand`
- `\Sylius\Bundle\CoreBundle\Command\CancelUnpaidOrdersCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\CancelUnpaidOrdersCommand`
- `\Sylius\Bundle\CoreBundle\Command\CheckRequirementsCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\CheckRequirementsCommand`
- `\Sylius\Bundle\CoreBundle\Command\InformAboutGUSCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\InformAboutGUSCommand`
- `\Sylius\Bundle\CoreBundle\Command\InstallAssetsCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\InstallAssetsCommand`
- `\Sylius\Bundle\CoreBundle\Command\InstallCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\InstallCommand`
- `\Sylius\Bundle\CoreBundle\Command\InstallDatabaseCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\InstallDatabaseCommand`
- `\Sylius\Bundle\CoreBundle\Command\InstallSampleDataCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\InstallSampleDataCommand`
- `\Sylius\Bundle\CoreBundle\Command\JwtConfigurationCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\JwtConfigurationCommand`
- `\Sylius\Bundle\CoreBundle\Command\SetupCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\SetupCommand`
- `\Sylius\Bundle\CoreBundle\Command\ShowAvailablePluginsCommand` to `\Sylius\Bundle\CoreBundle\Console\Command\ShowAvailablePluginsCommand`
1. In version 2.0 introduces a significant restructuring of our class system to enhance efficiency and clarity. The changes are as follows:
- `Message` will be migrated to `Command`.
- `MessageDispatcher` will be migrated to `CommandDispatcher`.
- `MessageHandler` will be migrated to `CommandHandler`.
- Example: Within the `Sylius\Bundle\CoreBundle`, the `MessageHandler\OrderHandler` class will be migrated to `CommandHandler\OrderHandler`. This pattern will be mirrored across other bundles in the system.
1. The behavior of the `sylius:install:setup` command has changed, because `Sylius\Bundle\CoreBundle\Installer\Setup\LocaleSetup` has been updated.
Now, it automatically replaces the existing `locale` parameter in the configuration with the one provided for the store.
1. A new parameter has been added to specify the validation groups for a given catalog promotion scope.
If you have any custom validation groups for your catalog promotion scope, you need to add them to your `config/packages/_sylius.yaml` file.
Additionally, if you have your own catalog promotion scope and want to add your validation groups, you can add another key to the `catalog_promotion_scope.validation_groups` parameter.
This is handled by `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionScopeGroupValidator` and it resolves the groups based on the type of the passed catalog promotion scope.
```yaml
sylius_promotion:
catalog_promotion_scope:
validation_groups:
for_products:
- 'sylius'
- 'sylius_catalog_promotion_scope_for_products'
for_taxons:
- 'sylius'
- 'sylius_catalog_promotion_scope_for_taxons'
your_scope:
- 'sylius'
- 'your_custom_validation_group'
```
Along with this update, constraints have been removed from specific rule form types. The affected form types include:
- `Sylius\Bundle\CoreBundle\Form\Type\CatalogPromotionScope\ForProductsScopeConfigurationType`
- `Sylius\Bundle\CoreBundle\Form\Type\CatalogPromotionScope\ForTaxonsScopeConfigurationType`
- `Sylius\Bundle\CoreBundle\Form\Type\CatalogPromotionScope\ForVariantsScopeConfigurationType`
The constraints previously defined in these forms are now in `src/Sylius/Bundle/CoreBundle/Resources/config/validation/CatalogPromotionScope.xml` and managed via the new validation groups parameters in the configuration.
1. A new parameter has been added to specify the validation groups for a given catalog promotion action.
If you have any custom validation groups for your catalog promotion action, you need to add them to your `config/packages/_sylius.yaml` file.
Additionally, if you have your own catalog promotion action and want to add your validation groups, you can add another key to the `catalog_promotion_action.validation_groups` parameter.
This is handled by `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionActionGroupValidator` and it resolves the groups based on the type of the passed catalog promotion action.
```yaml
sylius_promotion:
catalog_promotion_action:
validation_groups:
percentage_discount:
- 'sylius'
- 'sylius_catalog_promotion_action_percentage_discount'
fixed_discount:
- 'sylius'
- 'sylius_catalog_promotion_action_fixed_discount'
your_action:
- 'sylius'
- 'your_custom_validation_group'
```
Along with this update, constraints have been removed from specific rule form types. The affected form types include:
- `Sylius\Bundle\PromotionBundle\Form\Type\CatalogPromotionAction\FixedDiscountActionConfigurationType`
- `Sylius\Bundle\PromotionBundle\Form\Type\CatalogPromotionAction\PercentageDiscountActionConfigurationType`
The constraints previously defined in these forms are now in `src/Sylius/Bundle/PromotionBundle/Resources/config/validation/CatalogPromotionAction.xml` and `src/Sylius/Bundle/CoreBundle/Resources/config/validation/CatalogPromotionAction.xml` and are managed via the new validation groups parameters in the configuration.
1. Since catalog promotion action and scope validations have been rewritten to be more inline with symfony, the previous abstraction has been deprecated. This includes:
- `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionAction\ActionValidatorInterface`
- `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionScope\ScopeValidatorInterface`
- `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionActionValidator`
- `Sylius\Bundle\PromotionBundle\Validator\CatalogPromotionScopeValidator`
1. Class `Sylius\Component\Promotion\Checker\Rule\CartQuantityRuleChecker` has been deprecated.
Use `Sylius\Component\Core\Promotion\Checker\Rule\CartQuantityRuleChecker` instead.
1. Class `Sylius\Component\Promotion\Checker\Rule\ItemTotalRuleChecker` has been deprecated.
Use `Sylius\Component\Core\Promotion\Checker\Rule\ItemTotalRuleChecker` instead.
1. The first parameter of the constructor in the `\Sylius\Component\Core\Promotion\Checker\Rule\ItemTotalRuleChecker` class has been deprecated and will be removed in version 2.0.
1. The service definition for `sylius.promotion_rule_checker.item_total` has been updated. The class has been changed from `Sylius\Component\Promotion\Checker\Rule\ItemTotalRuleChecker` to `Sylius\Component\Core\Promotion\Checker\Rule\ItemTotalRuleChecker`.
1. Sylius Mailer email configuration keys in the `src/Sylius/Bundle/CoreBundle/Resources/config/app/sylius/sylius_mailer.yml` file have been changed:
Deprecated:
```yaml
sylius_mailer:
emails:
account_verification_token:
subject: sylius.emails.user.verification_token.subject
```
New:
```yaml
sylius_mailer:
emails:
account_verification:
subject: sylius.email.user.account_verification.subject
```
1. Translation keys in the `Sylius\Bundle\CoreBundle\Resources\translations\messages.en.yml` under the `sylius.email` key have been changed:
Deprecated:
```yaml
sylius:
email:
verification_token:
hello: 'Hello'
message: 'Verify your account with token: '
subject: 'Email address verification'
to_verify_your_email_address: 'To verify your email address - click the link below'
verify_your_email_address: 'Verify your email address'
```
New:
```yaml
sylius:
email:
user:
account_verification:
greeting: 'Hello'
message: 'Verify your account with token: '
statement: 'Verify your email address'
strategy: 'To verify your email address - click the link below'
subject: 'Email address verification'
```
1 Extracted the section responsible for the `ShopBundle` from `@SyliusCore/Email/accountVerification.html.twig` and relocated it to `@SyliusShop/Email/verification.html.twig`.

View file

@ -1,5 +1,13 @@
# UPGRADE FROM `v1.X.X` TO `v2.0.0`
1. Non-prefix serialization groups in Sylius resources have been removed.
If you have extended any of them, you must prefix them with `sylius:`, for example:
```diff
- #[Groups(['admin:product:index'])]
+ #[Groups(['sylius:admin:product:index'])]
```
## Codebase
* Doctrine MongoDB and PHPCR is not longer supported in ResourceBundle and GridBundle:

228
UPGRADE-API-1.13.md Normal file
View file

@ -0,0 +1,228 @@
# UPGRADE FROM `v1.12.x` TO `v1.13.0`
1. All the `:read` serialization groups are now split to `index` and `show`.
By this change, the `:read` serialization group is now deprecated and will no more used in the future.
There is a BC layer that will allow you to use the `:read` serialization group `Sylius\Bundle\ApiBundle\SerializerContextBuilder\ReadOperationContextBuilder` by adding the `read` serialization group to your context.
Inside of this service there are 2 configurable parameters `$skipAddingReadGroup` and `$skipAddingIndexAndShowGroups` that will allow you to skip adding the chosen serialization group to your context.
To configure skipping adding the index and show or read serialization groups to the context, add the following configuration to your `config/packages/_sylius.yaml` file:
```yaml
sylius_api:
serialization_groups:
skip_adding_index_and_show_groups: true
skip_adding_read_group: true
```
1. Sylius serialization groups have been updated with a new prefix of `sylius:some_resource`.
If you extend any of the Sylius resources, you should update your serialization groups to use the new prefix.
Non-prefix serialization groups are deprecated and will be removed in Sylius 2.0.
1. The constructor of `Sylius\Bundle\ApiBundle\Serializer\ChannelDenormalizer` has been changed:
```diff
public function __construct(
private FactoryInterface $channelPriceHistoryConfigFactory,
+ private FactoryInterface $shopBillingDataFactory
) {
}
```
1. The constructor of `Sylius\Bundle\ApiBundle\EventSubscriber\TaxonDeletionEventSubscriber` has changed:
````diff
public function __construct(
private ChannelRepositoryInterface $channelRepository,
+ private TaxonInPromotionRuleCheckerInterface $taxonInPromotionRuleChecker,
) {
}
````
1. The signature of constructor of `Sylius\Bundle\ApiBundle\Command\Account\ChangeShopUserPassword` command changed:
````diff
public function __construct(
- public ?string $newPassword,
+ public string $newPassword,
- public ?string $confirmNewPassword,
+ public string $confirmNewPassword,
- public ?string $currentPassword,
+ public string $currentPassword,
) {
}
````
1. The constructor signature of `Sylius\Bundle\ApiBundle\Command\Catalog\AddProductReview` changed:
````diff
public function __construct(
- public ?string $title,
+ public string $title,
- public ?int $rating,
+ public int $rating,
- public ?string $comment,
+ public string $comment,
public string $productCode,
public ?string $email = null,
) {
}
````
1. The constructor signature of `Sylius\Bundle\ApiBundle\Command\Account\VerifyCustomerAccount` changed:
````diff
public function __construct(
- public $token,
+ public string $token,
+ public ?string $channelCode = null,
+ public ?string $localeCode = null,
) {
}
````
1. The item operation paths for ProductVariantTranslation resource changed:
- `GET /admin/product-variant-translation/{id}` -> `GET /admin/product-variant-translations/{id}`
- `GET /shop/product-variant-translation/{id}` -> `GET /shop/product-variant-translations/{id}`
1. Typo in the constraint validator's alias returned by `Sylius\Bundle\ApiBundle\Validator\Constraints\ChangedItemQuantityInCartValidator::validatedBy` has been fixed.
Previously it was `sylius_api_validator_changed_item_guantity_in_cart` and now it is `sylius_api_validator_changed_item_quantity_in_cart`.
1. The `ApiPlatform\Core\Bridge\Symfony\Bundle\Action\SwaggerUiAction` controller has been removed.
Therefore, the `api_platform.swagger.action.ui` service ID points to the API Platform's `SwaggerUiAction` controller.
1. The following services have been removed:
* `Sylius\Bundle\ApiBundle\Swagger\AdminAuthenticationTokenDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ShopAuthenticationTokenDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ProductDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ProductImageDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ProductSlugDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ProductVariantDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\ShippingMethodDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\PathHiderDocumentationNormalizer`
* `Sylius\Bundle\ApiBundle\Swagger\AcceptLanguageHeaderDocumentationNormalizer`
Responsibility of these services has been moved to the corresponding services tagged with `sylius.open_api.modifier`:
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\AdminAuthenticationTokenDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ShopAuthenticationTokenDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ProductDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ProductImageDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ProductSlugDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ProductVariantDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\ShippingMethodDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\PathHiderDocumentationModifier`
* `Sylius\Bundle\ApiBundle\OpenApi\Documentation\AcceptLanguageHeaderDocumentationModifier`
1. All usages of `ApiPlatform\Core\Api\IriConverterInterface` have been switched to its non-deprecated counterpart `ApiPlatform\Api\IriConverterInterface`.
Due to that, the constructor and usage in the following classes have been changed accordingly:
* `Sylius\Bundle\ApiBundle\Controller\GetProductBySlugAction`
* `Sylius\Bundle\ApiBundle\Controller\UploadAvatarImageAction`
* `Sylius\Bundle\ApiBundle\EventListener\AdminAuthenticationSuccessListener`
* `Sylius\Bundle\ApiBundle\EventListener\AuthenticationSuccessListener`
* `Sylius\Bundle\ApiBundle\Filter\Doctrine\CatalogPromotionChannelFilter`
* `Sylius\Bundle\ApiBundle\Filter\Doctrine\ProductVariantCatalogPromotionFilter`
* `Sylius\Bundle\ApiBundle\Filter\Doctrine\ProductVariantOptionValueFilter`
* `Sylius\Bundle\ApiBundle\Filter\Doctrine\ProductVariantOptionValueFilter`
* `Sylius\Bundle\ApiBundle\Filter\Doctrine\TaxonFilter`
* `Sylius\Bundle\ApiBundle\Serializer\ChannelPriceHistoryConfigDenormalizer`
* `Sylius\Bundle\ApiBundle\Serializer\ProductNormalizer`
* `Sylius\Bundle\ApiBundle\Serializer\ProductVariantNormalizer`
* `Sylius\Bundle\ApiBundle\Serializer\ZoneDenormalizer`
1. The `Sylius\Bundle\ApiBundle\Filter\Doctrine\CatalogPromotionChannelFilter` service and class has been renamed to `Sylius\Bundle\ApiBundle\Filter\Doctrine\ChannelsAwareChannelFilter`.
1. The `sylius.api.product_taxon_filter` filter has been removed and its functionality has been superseded by the `sylius.api.search_filter.taxon.code` filter. The usage stays the same.
1. Update in Translations Handling
The process for creating or updating translations via the API has been refined. Now, the locale for each translation
is determined directly from its key, making the explicit transmission of the `locale` field redundant. Although the API
continues to support the explicit sending of the `locale` field, it is essential that this explicitly sent locale matches
the key in the translation array. In cases of a mismatch between the key and an explicitly sent locale, the API will
respond with a `Sylius\Bundle\ApiBundle\Exception\TranslationLocaleMismatchException`.
1. The following Command Handlers constructor signatures have changed:
`Sylius\Bundle\ApiBundle\CommandHandler\Account\SendAccountRegistrationEmailHandler`:
```diff
public function __construct(
private UserRepositoryInterface $shopUserRepository,
private ChannelRepositoryInterface $channelRepository,
- private SenderInterface $emailSender,
+ private Sylius\Bundle\CoreBundle\Mailer\AccountRegistrationEmailManagerInterface $accountRegistrationEmailManager,
) {
}
```
`Sylius\Bundle\ApiBundle\CommandHandler\Account\SendAccountVerificationEmailHandler`:
```diff
public function __construct(
private UserRepositoryInterface $shopUserRepository,
private ChannelRepositoryInterface $channelRepository,
- private SenderInterface $emailSender,
+ private Sylius\Bundle\CoreBundle\Mailer\AccountVerificationEmailManagerInterface $accountVerificationEmailManager,
) {
}
```
`Sylius\Bundle\ApiBundle\CommandHandler\Account\SendResetPasswordEmailHandler`:
```diff
public function __construct(
- private SenderInterface $emailSender,
private UserRepositoryInterface $shopUserRepository,
private ChannelRepositoryInterface $channelRepository,
+ private Sylius\Bundle\CoreBundle\Mailer\ResetPasswordEmailManagerInterface $resetPasswordEmailManager,
) {
}
```
`Sylius\Bundle\ApiBundle\CommandHandler\Checkout\SendOrderConfirmationHandler`:
```diff
public function __construct(
- private SenderInterface $emailSender,
private OrderRepositoryInterface $orderRepository,
+ private Sylius\Bundle\CoreBundle\Mailer\OrderEmailManagerInterface $orderEmailManager,
) {
}
```
`Sylius\Bundle\ApiBundle\CommandHandler\Checkout\SendShipmentConfirmationEmailHandler`:
```diff
public function __construct(
- private SenderInterface $emailSender,
private ShipmentRepositoryInterface $shipmentRepository,
+ private Sylius\Bundle\CoreBundle\Mailer\ShipmentEmailManagerInterface $shipmentEmailManager,
) {
}
```
`Sylius\Bundle\ApiBundle\CommandHandler\SendContactRequestHandler`:
```diff
public function __construct(
- private SenderInterface $emailSender,
private ChannelRepositoryInterface $channelRepository,
+ private Sylius\Bundle\CoreBundle\Mailer\ContactEmailManagerInterface $contactEmailManager,
) {
}
```
`Sylius\Bundle\CoreBundle\MessageHandler\Admin\Account\SendResetPasswordEmailHandler`:
```diff
public function __construct(
private UserRepositoryInterface $shopUserRepository,
- private SenderInterface $emailSender,
+ private Sylius\Bundle\CoreBundle\Mailer\ResetPasswordEmailManagerInterface $resetPasswordEmailManager,
) {
}
```
1. Disabled product and taxon editing at `/admin/product-taxons/{id}` operation to improve data integrity. To modify a productTaxon, remove the existing association and create a new one.
1. The keys for adjustment endpoints' responses have been changed from `order_item` to `orderItem` and `order_item_unit` to `orderItemUnit`.
1. The following shop endpoints for getting the translation resources have been removed:
* `GET `/shop/taxon-translations/{id}`
* `GET `/shop/product-translations/{id}`
* `GET `/shop/product-variant-translations/{id}`
* `GET `/shop/shipping-method-translations/{id}`
The fields those endpoint were exposing are available on their respective translation subject resources.

View file

@ -0,0 +1,156 @@
⚙️ Upgrade from Sylius 1.12 with PriceHistoryPlugin to Sylius 1.13
==================================================================
We encourage you to use the upgrade instructions based on Rector as it is more convenient and faster to accomplish.
The rector installation guide is available [here](UPGRADE-FROM-1.12-WITH-PRICE-HISTORY-PLUGIN-TO-1.13.md).
Legacy upgrade
--------------
1. Remove the PriceHistoryPlugin from composer.json by running:
```bash
composer remove sylius/price-history-plugin --no-scripts
```
1. Make sure to remove the following config from your `config/packages/sylius_price_history_plugin.yaml` file:
```diff
- - { resource: "@SyliusPriceHistoryPlugin/config/config.yaml" }
```
And the route from your `config/routes/sylius_price_history_plugin.yaml`:
```diff
- sylius_price_history_admin:
- resource: '@SyliusPriceHistoryPlugin/config/admin_routing.yaml'
- prefix: '/%sylius_admin.path_name%'
```
And also remove the plugin from your `packages/bundles.php` file:
```diff
- Sylius\PriceHistoryPlugin\SyliusPriceHistoryPlugin::class => ['all' => true],
```
1. Update the `Channel` entity to use interface from `Core`:
```diff
- use Sylius\PriceHistoryPlugin\Domain\Model\ChannelInterface;
+ use Sylius\Component\Core\Model\ChannelInterface;
```
Then remove the trait:
```diff
- use ChannelPriceHistoryConfigAwareTrait;
```
1. Update the `ChannelPricing` entity to use interface from `Core`:
```diff
- use Sylius\PriceHistoryPlugin\Domain\Model\ChannelPricingInterface;
+ use Sylius\Component\Core\Model\ChannelPricingInterface;
```
Then remove the trait:
```diff
- use LowestPriceBeforeDiscountAwareTrait;
```
1. Update your resources configuration for `ChannelPricingLogEntry` and `ChannelPriceHistoryConfig` if you have changed them in your project:
```diff
- sylius_price_history:
- batch_size: 100
+ sylius_core:
+ price_history:
+ batch_size: 100
resources:
channel_price_history_config:
classes:
model: App\Entity\ChannelPriceHistoryConfig
...
channel_pricing_log_entry:
classes:
model: App\Entity\ChannelPricingLogEntry
...
```
1. The class `Sylius\PriceHistoryPlugin\Infrastructure\EventSubscriber\ChannelPricingLogEntryEventSubscriber` has been replaced by `Sylius\Bundle\CoreBundle\PriceHistory\EventListener\ChannelPricingLogEntryEventListener`.
1. Change namespaces from the plugin to correct ones:
```
Sylius\PriceHistoryPlugin\Application\Checker\ProductVariantLowestPriceDisplayChecker => Sylius\Component\Core\Checker\ProductVariantLowestPriceDisplayChecker
Sylius\PriceHistoryPlugin\Application\Checker\ProductVariantLowestPriceDisplayCheckerInterface => Sylius\Component\Core\Checker\ProductVariantLowestPriceDisplayCheckerInterface
Sylius\PriceHistoryPlugin\Application\Command\ApplyLowestPriceOnChannelPricings => Sylius\Bundle\CoreBundle\PriceHistory\Command\ApplyLowestPriceOnChannelPricings
Sylius\PriceHistoryPlugin\Application\CommandDispatcher\BatchedApplyLowestPriceOnChannelPricingsCommandDispatcher => Sylius\Bundle\CoreBundle\PriceHistory\CommandDispatcher\BatchedApplyLowestPriceOnChannelPricingsCommandDispatcher
Sylius\PriceHistoryPlugin\Application\CommandDispatcher\ApplyLowestPriceOnChannelPricingsCommandDispatcherInterface => Sylius\Bundle\CoreBundle\PriceHistory\CommandDispatcher\ApplyLowestPriceOnChannelPricingsCommandDispatcherInterface
Sylius\PriceHistoryPlugin\Application\CommandHandler\ApplyLowestPriceOnChannelPricingsHandler => Sylius\Bundle\CoreBundle\PriceHistory\CommandHandler\ApplyLowestPriceOnChannelPricingsHandler
Sylius\PriceHistoryPlugin\Application\Logger\PriceChangeLogger => Sylius\Bundle\CoreBundle\PriceHistory\Logger\PriceChangeLogger
Sylius\PriceHistoryPlugin\Application\Logger\PriceChangeLoggerInterface => Sylius\Bundle\CoreBundle\PriceHistory\Logger\PriceChangeLoggerInterface
Sylius\PriceHistoryPlugin\Application\Processor\ProductLowestPriceBeforeDiscountProcessor => Sylius\Bundle\CoreBundle\PriceHistory\Processor\ProductLowestPriceBeforeDiscountProcessor
Sylius\PriceHistoryPlugin\Application\Processor\ProductLowestPriceBeforeDiscountProcessorInterface => Sylius\Bundle\CoreBundle\PriceHistory\Processor\ProductLowestPriceBeforeDiscountProcessorInterface
Sylius\PriceHistoryPlugin\Application\Remover\ChannelPricingLogEntriesRemoverInterface => Sylius\Bundle\CoreBundle\PriceHistory\Remover\ChannelPricingLogEntriesRemoverInterface
Sylius\PriceHistoryPlugin\Application\Templating\Helper\PriceHelper => Sylius\Bundle\CoreBundle\Templating\Helper\PriceHelper
Sylius\PriceHistoryPlugin\Application\Validator\ResourceInputDataPropertiesValidatorInterface => Sylius\Bundle\ApiBundle\Validator\ResourceInputDataPropertiesValidatorInterface
Sylius\PriceHistoryPlugin\Domain\Factory\ChannelFactory => Sylius\Component\Core\Factory\ChannelFactory
Sylius\PriceHistoryPlugin\Domain\Factory\ChannelPricingLogEntryFactory => Sylius\Component\Core\Factory\ChannelPricingLogEntryFactory
Sylius\PriceHistoryPlugin\Domain\Factory\ChannelPricingLogEntryFactoryInterface => Sylius\Component\Core\Factory\ChannelPricingLogEntryFactoryInterface
Sylius\PriceHistoryPlugin\Domain\Model\ChannelInterface => Sylius\Component\Core\Model\ChannelInterface
Sylius\PriceHistoryPlugin\Domain\Model\ChannelPriceHistoryConfig => Sylius\Component\Core\Model\ChannelPriceHistoryConfig
Sylius\PriceHistoryPlugin\Domain\Model\ChannelPricingLogEntry => Sylius\Component\Core\Model\ChannelPricingLogEntry
Sylius\PriceHistoryPlugin\Domain\Model\ChannelPriceHistoryConfigInterface => Sylius\Component\Core\Model\ChannelPriceHistoryConfigInterface
Sylius\PriceHistoryPlugin\Domain\Model\ChannelPricingInterface => Sylius\Component\Core\Model\ChannelPricingInterface
Sylius\PriceHistoryPlugin\Domain\Model\ChannelPricingLogEntryInterface => Sylius\Component\Core\Model\ChannelPricingLogEntryInterface
Sylius\PriceHistoryPlugin\Domain\Model\LowestPriceBeforeDiscountAwareInterface => Sylius\Component\Core\Model\ChannelPricingInterface
Sylius\PriceHistoryPlugin\Domain\Repository\ChannelPricingLogEntryRepositoryInterface => Sylius\Component\Core\Repository\ChannelPricingLogEntryRepositoryInterface
Sylius\PriceHistoryPlugin\Infrastructure\Cli\Command\ClearPriceHistoryCommand => Sylius\Bundle\CoreBundle\PriceHistory\Cli\Command\ClearPriceHistoryCommand
Sylius\PriceHistoryPlugin\Infrastructure\Doctrine\ORM\ChannelPricingLogEntryRepository => Sylius\Component\Core\Repository\ChannelPricingLogEntryRepository
Sylius\PriceHistoryPlugin\Infrastructure\Doctrine\ORM\ChannelPricingLogEntryRepositoryInterface => Sylius\Component\Core\Repository\ChannelPricingLogEntryRepositoryInterface
Sylius\PriceHistoryPlugin\Infrastructure\EntityObserver\CreateLogEntryOnPriceChangeObserver => Sylius\Bundle\CoreBundle\PriceHistory\EntityObserver\CreateLogEntryOnPriceChangeObserver
Sylius\PriceHistoryPlugin\Infrastructure\EntityObserver\EntityObserverInterface => Sylius\Bundle\CoreBundle\PriceHistory\EntityObserver\EntityObserverInterface
Sylius\PriceHistoryPlugin\Infrastructure\EntityObserver\ProcessLowestPricesOnChannelChangeObserver => Sylius\Bundle\CoreBundle\PriceHistory\EntityObserver\ProcessLowestPricesOnChannelChangeObserver
Sylius\PriceHistoryPlugin\Infrastructure\EntityObserver\ProcessLowestPricesOnChannelPriceHistoryConfigChangeObserver => Sylius\Bundle\CoreBundle\PriceHistory\EntityObserver\ProcessLowestPricesOnChannelPriceHistoryConfigChangeObserver
Sylius\PriceHistoryPlugin\Infrastructure\Event\OldChannelPricingLogEntriesEvents => Sylius\Bundle\CoreBundle\PriceHistory\Event\OldChannelPricingLogEntriesEvents
Sylius\PriceHistoryPlugin\Infrastructure\EventListener\OnFlushEntityObserverListener => Sylius\Bundle\CoreBundle\PriceHistory\EventListener\OnFlushEntityObserverListener
Sylius\PriceHistoryPlugin\Infrastructure\EventSubscriber\ChannelPricingLogEntryEventSubscriber => Sylius\Bundle\CoreBundle\PriceHistory\EventListener\ChannelPricingLogEntryEventListener
Sylius\PriceHistoryPlugin\Infrastructure\Form\Extension\ChannelTypeExtension => Sylius\Bundle\CoreBundle\Form\Extension\ChannelTypeExtension
Sylius\PriceHistoryPlugin\Infrastructure\Form\Type\ChannelPriceHistoryConfigType => Sylius\Bundle\CoreBundle\Form\Type\ChannelPriceHistoryConfigType
Sylius\PriceHistoryPlugin\Infrastructure\Provider\ProductVariantsPricesProvider => Sylius\Component\Core\Provider\ProductVariantsPricesProvider
Sylius\PriceHistoryPlugin\Infrastructure\Remover\ChannelPricingLogEntriesRemover' => 'Sylius\Bundle\CoreBundle\PriceHistory\Remover\ChannelPricingLogEntriesRemover'
Sylius\PriceHistoryPlugin\Infrastructure\Serializer\ChannelDenormalizer => Sylius\Bundle\ApiBundle\Serializer\ChannelDenormalizer
Sylius\PriceHistoryPlugin\Infrastructure\Serializer\ChannelPriceHistoryConfigDenormalizer => Sylius\Bundle\ApiBundle\Serializer\ChannelPriceHistoryConfigDenormalizer
Sylius\PriceHistoryPlugin\Infrastructure\Serializer\ProductVariantNormalizer => Sylius\Bundle\ApiBundle\Serializer\ProductVariantNormalizer
Sylius\PriceHistoryPlugin\Infrastructure\Twig\PriceExtension => Sylius\Bundle\CoreBundle\Twig\PriceExtension
Sylius\PriceHistoryPlugin\Infrastructure\Twig\SyliusVersionExtension => Sylius\Bundle\CoreBundle\Twig\SyliusVersionExtension
Sylius\PriceHistoryPlugin\Infrastructure\Validator\ResourceApiInputDataPropertiesValidator => Sylius\Bundle\ApiBundle\Validator\ResourceApiInputDataPropertiesValidator
```
1. The `Sylius\PriceHistoryPlugin\Application\Calculator\ProductVariantLowestPriceCalculator` class along with its interface has been removed.
If you have used it in your project, you should also remove it from your code.
Use `Sylius\Component\Core\Calculator\ProductVariantPriceCalculator` instead, as it has been extended with the `calculateLowestPrice` method.
1. Go through the rest of the [Sylius 1.13 upgrade file](UPGRADE-1.13.md).

View file

@ -0,0 +1,86 @@
⚙️ Upgrade from Sylius 1.12 with PriceHistoryPlugin to Sylius 1.13
==================================================================
We encourage you to use the upgrade instructions based on Rector as it is more convenient and faster to accomplish.
The legacy installation guide is available [here](UPGRADE-FROM-1.12-WITH-PRICE-HISTORY-PLUGIN-TO-1.13-LEGACY.md).
Upgrade with Rector
-------------------
1. Remove the PriceHistoryPlugin from composer.json by running:
```bash
composer remove sylius/price-history-plugin --no-scripts
```
1. Update your `<project_root>/rector.php` file:
```diff
+ use Sylius\SyliusRector\Set\SyliusPriceHistory;
return static function (RectorConfig $rectorConfig): void {
// ...
- $rectorConfig->sets([SyliusPriceHistory::PRICE_HISTORY_PLUGIN])
+ $rectorConfig->sets([SyliusPriceHistory::UPGRADE_SYLIUS_1_12_WITH_PRICE_HISTORY_PLUGIN_TO_SYLIUS_1_13]);
};
```
1. Run:
```bash
vendor/bin/rector
```
1. Make sure to remove the following config from your `config/packages/sylius_price_history_plugin.yaml` file:
```diff
- - { resource: "@SyliusPriceHistoryPlugin/config/config.yaml" }
```
And also the route from your `config/routes/sylius_price_history_plugin.yaml`:
```diff
- sylius_price_history_admin:
- resource: '@SyliusPriceHistoryPlugin/config/admin_routing.yaml'
- prefix: '/%sylius_admin.path_name%'
```
1. Update your resources configuration for `ChannelPricingLogEntry` and `ChannelPriceHistoryConfig` if you have changed them in your project:
```diff
- sylius_price_history:
- batch_size: 100
+ sylius_core:
+ price_history:
+ batch_size: 100
resources:
channel_price_history_config:
classes:
model: App\Entity\ChannelPriceHistoryConfig
...
channel_pricing_log_entry:
classes:
model: App\Entity\ChannelPricingLogEntry
...
```
1. The class `Sylius\PriceHistoryPlugin\Infrastructure\EventSubscriber\ChannelPricingLogEntryEventSubscriber` has been replaced by `Sylius\Bundle\CoreBundle\PriceHistory\EventListener\ChannelPricingLogEntryEventListener`.
1. The `Sylius\PriceHistoryPlugin\Application\Calculator\ProductVariantLowestPriceCalculator` class along with its interface has been removed.
If you have used it in your project, you should also remove it from your code.
Use `Sylius\Component\Core\Calculator\ProductVariantPriceCalculator` instead, as it has been extended with the `calculateLowestPrice` method.
1. Go through the rest of the [Sylius 1.13 upgrade file](UPGRADE-1.13.md).

View file

@ -15,6 +15,10 @@
declare(strict_types=1);
@trigger_error('The "TestAppKernel" class located at "app/TestAppKernel.php" is deprecated since Sylius 1.3. Use "Kernel" class located at "src/Kernel.php" instead.', \E_USER_DEPRECATED);
trigger_deprecation(
'sylius/sylius',
'1.3',
'The "TestAppKernel" class located at "app/TestAppKernel.php" is deprecated. Use "Kernel" class located at "src/Kernel.php" instead.',
);
class_alias(Kernel::class, TestAppKernel::class);

View file

@ -15,4 +15,8 @@
declare(strict_types=1);
@trigger_error('Importing files from Sylius/Sylius\'s "app/config" directory is deprecated since Sylius 1.3.', \E_USER_DEPRECATED);
trigger_deprecation(
'sylius/sylius',
'1.3',
'Importing files from Sylius/Sylius\'s "app/config" directory is deprecated.',
);

View file

@ -17,6 +17,10 @@ declare(strict_types=1);
use Symfony\Component\Routing\RouteCollection;
@trigger_error('Importing files from Sylius/Sylius\'s "app/config" directory is deprecated since Sylius 1.3.', \E_USER_DEPRECATED);
trigger_deprecation(
'sylius/sylius',
'1.3',
'Importing files from Sylius/Sylius\'s "app/config" directory is deprecated.',
);
return new RouteCollection();

View file

@ -23,13 +23,44 @@
"Behat\\Testwork\\Tester\\Setup\\Teardown",
"Doctrine\\DBAL\\Platforms\\MySqlPlatform",
"Doctrine\\DBAL\\Platforms\\MySQLPlatform",
"Http\\Client\\HttpClient",
"HWI\\Bundle\\OAuthBundle\\Connect\\AccountConnectorInterface",
"HWI\\Bundle\\OAuthBundle\\OAuth\\Response\\UserResponseInterface",
"HWI\\Bundle\\OAuthBundle\\Security\\Core\\User\\OAuthAwareUserProviderInterface",
"League\\Flysystem\\FilesystemOperator",
"Symfony\\Component\\Security\\Core\\Encoder\\EncoderFactoryInterface",
"Payum\\Core\\Action\\ActionInterface",
"Payum\\Core\\Action\\GatewayAwareAction",
"Payum\\Core\\Bridge\\Spl\\ArrayObject",
"Payum\\Core\\Exception\\RequestNotSupportedException",
"Payum\\Core\\Extension\\Context",
"Payum\\Core\\Extension\\ExtensionInterface",
"Payum\\Core\\HttpClientInterface",
"Payum\\Core\\Model\\GatewayConfig",
"Payum\\Core\\Model\\GatewayConfigInterface",
"Payum\\Core\\Model\\Identity",
"Payum\\Core\\Model\\Payment",
"Payum\\Core\\Model\\PaymentInterface",
"Payum\\Core\\Payum",
"Payum\\Core\\Request\\Authorize",
"Payum\\Core\\Request\\BaseGetStatus",
"Payum\\Core\\Request\\Capture",
"Payum\\Core\\Request\\Convert",
"Payum\\Core\\Request\\Generic",
"Payum\\Core\\Request\\GetStatusInterface",
"Payum\\Core\\Request\\Notify",
"Payum\\Core\\Security\\CryptedInterface",
"Payum\\Core\\Security\\GenericTokenFactoryInterface",
"Payum\\Core\\Security\\HttpRequestVerifierInterface",
"Payum\\Core\\Security\\TokenInterface",
"Payum\\Core\\Security\\Util\\Random",
"Payum\\Core\\Storage\\AbstractStorage",
"Payum\\Paypal\\ExpressCheckout\\Nvp\\PaypalExpressCheckoutGatewayFactory",
"Payum\\Stripe\\StripeCheckoutGatewayFactory",
"PHPUnit\\Framework\\ExpectationFailedException",
"Stripe\\Stripe"
"Psr\\Container\\ContainerInterface",
"Psr\\Http\\Message\\RequestFactoryInterface",
"Psr\\Http\\Message\\StreamFactoryInterface",
"Symfony\\Component\\Security\\Core\\Encoder\\EncoderFactoryInterface"
],
"php-core-extensions" : [
"Core",

View file

@ -1,7 +1,7 @@
{
"name": "sylius/sylius",
"type": "library",
"version": "v1.12.14-dev",
"version": "v1.13.0-dev",
"description": "E-Commerce platform for PHP, based on Symfony framework.",
"homepage": "https://sylius.com",
"license": "MIT",
@ -20,7 +20,7 @@
}
],
"require": {
"php": "^8.0",
"php": "^8.1",
"ext-dom": "*",
"ext-exif": "*",
"ext-fileinfo": "*",
@ -29,28 +29,29 @@
"ext-hash": "*",
"ext-intl": "*",
"ext-json": "*",
"api-platform/core": "^2.6",
"ext-simplexml": "*",
"api-platform/core": "^2.7.10",
"babdev/pagerfanta-bundle": "^3.0",
"behat/transliterator": "^1.3",
"doctrine/collections": "^1.6",
"doctrine/common": "^3.2",
"doctrine/dbal": "^2.7 || ^3.0",
"doctrine/doctrine-bundle": "^1.12 || ^2.0",
"doctrine/dbal": "^3.0",
"doctrine/doctrine-bundle": "^1.12 || ^2.3.1",
"doctrine/doctrine-migrations-bundle": "^3.0.1",
"doctrine/event-manager": "^1.1",
"doctrine/inflector": "^1.4 || ^2.0",
"doctrine/migrations": "^3.0",
"doctrine/migrations": "^3.5.5",
"doctrine/orm": "^2.13",
"doctrine/persistence": "^2.3 || ^3.0",
"egulias/email-validator": "^3.1",
"enshrined/svg-sanitize": "^0.15.4 || ^0.16",
"enshrined/svg-sanitize": "^0.16",
"fakerphp/faker": "^1.10",
"friendsofphp/proxy-manager-lts": "^1.0.7",
"friendsofsymfony/rest-bundle": "^3.0",
"gedmo/doctrine-extensions": "^3.2",
"guzzlehttp/guzzle": "^6.5",
"guzzlehttp/psr7": "^1.8",
"jms/serializer-bundle": "^4.0",
"guzzlehttp/guzzle": "^6.5 || ^7.0",
"guzzlehttp/psr7": "^2.5",
"jms/serializer-bundle": "^4.2",
"knplabs/gaufrette": "^0.10 || ^0.11",
"knplabs/knp-gaufrette-bundle": "^0.7 || ^0.8",
"knplabs/knp-menu": "^3.1",
@ -58,23 +59,26 @@
"laminas/laminas-stdlib": "^3.3.1",
"league/flysystem-bundle": "^2.4",
"lexik/jwt-authentication-bundle": "^2.11",
"liip/imagine-bundle": "^2.3",
"liip/imagine-bundle": "^2.10",
"nyholm/psr7": "^1.6",
"pagerfanta/pagerfanta": "^3.0",
"payum/payum": "^1.7.2",
"payum/offline": "^1.7.3",
"payum/payum-bundle": "^2.5",
"php-http/guzzle6-adapter": "^2.0",
"php-http/httplug": "^2.4",
"php-http/message-factory": "^1.0",
"psr/cache": "^2.0",
"psr/http-client": "^1.0",
"psr/http-message": "^1.0",
"psr/log": "^2.0",
"ramsey/uuid": "^4.0",
"sonata-project/block-bundle": "^4.2",
"sonata-project/block-bundle": "^4.2 || ^5.0",
"stof/doctrine-extensions-bundle": "^1.4",
"sylius-labs/association-hydrator": "^1.1 || ^1.2",
"sylius-labs/doctrine-migrations-extra-bundle": "^0.1.4 || ^0.2",
"sylius-labs/polyfill-symfony-event-dispatcher": "^1.0.1",
"sylius-labs/polyfill-symfony-framework-bundle": "^1.0 || ^1.1",
"sylius-labs/polyfill-symfony-security": "^1.1",
"sylius/calendar": "^0.3 || ^0.4",
"sylius/calendar": "^0.3 || ^0.4 || ^0.5",
"sylius/fixtures-bundle": "^1.7",
"sylius/grid": "^1.11",
"sylius/grid-bundle": "^1.11",
@ -84,50 +88,53 @@
"sylius/resource": "^1.9",
"sylius/resource-bundle": "^1.9",
"sylius/theme-bundle": "^2.1.1 || ^2.3",
"symfony/asset": "^5.4 || ^6.0",
"symfony/config": "^5.4 || ^6.0",
"symfony/console": "^5.4 || ^6.0",
"symfony/dependency-injection": "^5.4 || ^6.0",
"symfony/asset": "^5.4.21 || ^6.4",
"symfony/config": "^5.4.21 || ^6.4",
"symfony/console": "^5.4.21 || ^6.4",
"symfony/cache-contracts": "^2.5 || ^3.0",
"symfony/dependency-injection": "^5.4.21 || ^6.4",
"symfony/deprecation-contracts": "^2.5",
"symfony/doctrine-bridge": "^5.4 || ^6.0",
"symfony/doctrine-messenger": "^5.4 || ^6.0",
"symfony/event-dispatcher": "^5.4 || ^6.0",
"symfony/expression-language": "^5.4 || ^6.0",
"symfony/filesystem": "^5.4 || ^6.0",
"symfony/finder": "^5.4 || ^6.0",
"symfony/form": "^5.4 || ^6.0",
"symfony/framework-bundle": "^5.4 || ^6.0",
"symfony/http-foundation": "^5.4 || ^6.0",
"symfony/http-kernel": "^5.4 || ^6.0",
"symfony/intl": "^5.4 || ^6.0",
"symfony/mailer": "^5.4 || ^6.0",
"symfony/messenger": "^5.4 || ^6.0",
"symfony/doctrine-bridge": "^5.4.21 || ^6.4",
"symfony/doctrine-messenger": "^5.4.21 || ^6.4",
"symfony/event-dispatcher": "^5.4.21 || ^6.4",
"symfony/expression-language": "^5.4.21 || ^6.4",
"symfony/filesystem": "^5.4.21 || ^6.4",
"symfony/finder": "^5.4.21 || ^6.4",
"symfony/form": "^5.4.21 || ^6.4",
"symfony/framework-bundle": "^5.4.21 || ^6.4",
"symfony/http-client": "^5.4.21 || ^6.4",
"symfony/http-foundation": "^5.4.21 || ^6.4",
"symfony/http-kernel": "^5.4.21 || ^6.4",
"symfony/intl": "^5.4.21 || ^6.4",
"symfony/mailer": "^5.4.21 || ^6.4",
"symfony/messenger": "^5.4.21 || ^6.4",
"symfony/monolog-bundle": "^3.5",
"symfony/options-resolver": "^5.4 || ^6.0",
"symfony/password-hasher": "^5.4 || ^6.0",
"symfony/options-resolver": "^5.4.21 || ^6.4",
"symfony/password-hasher": "^5.4.21 || ^6.4",
"symfony/polyfill-iconv": "^1.17",
"symfony/polyfill-intl-icu": "^1.22",
"symfony/polyfill-mbstring": "^1.17",
"symfony/polyfill-php80": "^1.17",
"symfony/process": "^5.4 || ^6.0",
"symfony/property-access": "^5.4 || ^6.0",
"symfony/property-info": "^5.4 || ^6.0",
"symfony/proxy-manager-bridge": "^5.4 || ^6.0",
"symfony/routing": "^5.4 || ^6.0",
"symfony/security-bundle": "^5.4 || ^6.0",
"symfony/security-core": "^5.4 || ^6.0",
"symfony/security-csrf": "^5.4 || ^6.0",
"symfony/security-http": "^5.4 || ^6.0",
"symfony/serializer": "^5.4 || ^6.0",
"symfony/process": "^5.4.21 || ^6.4",
"symfony/property-access": "^5.4.21 || ^6.4",
"symfony/property-info": "^5.4.21 || ^6.4",
"symfony/proxy-manager-bridge": "^5.4.21 || ^6.4",
"symfony/routing": "^5.4.21 || ^6.4",
"symfony/security-bundle": "^5.4.21 || ^6.4",
"symfony/security-core": "^5.4.21 || ^6.4",
"symfony/security-csrf": "^5.4.21 || ^6.4",
"symfony/security-http": "^5.4.21 || ^6.4",
"symfony/serializer": "^5.4.21 || ^6.4",
"symfony/service-contracts": "^2.5 || ^3.0",
"symfony/string": "^5.4 || ^6.0",
"symfony/templating": "^5.4 || ^6.0",
"symfony/translation": "^5.4 || ^6.0",
"symfony/string": "^5.4.21 || ^6.4",
"symfony/templating": "^5.4.21 || ^6.4",
"symfony/translation": "^5.4.21 || ^6.4",
"symfony/translation-contracts": "^2.5",
"symfony/twig-bundle": "^5.4 || ^6.0",
"symfony/validator": "^5.4 || ^6.0",
"symfony/twig-bundle": "^5.4.21 || ^6.4",
"symfony/validator": "^5.4.21 || ^6.4",
"symfony/webpack-encore-bundle": "^1.15",
"symfony/yaml": "^5.4 || ^6.0",
"symfony/workflow": "^5.4.21 || ^6.4",
"symfony/yaml": "^5.4.21 || ^6.4",
"twig/intl-extra": "^2.12 || ^3.4",
"twig/twig": "^2.12 || ^3.3",
"webmozart/assert": "^1.9",
@ -179,17 +186,10 @@
"sylius/user-bundle": "self.version"
},
"conflict": {
"api-platform/core": "2.7.0",
"doctrine/doctrine-bundle": "2.3.0",
"doctrine/migrations": "3.5.3",
"doctrine/orm": ">= 2.16.0",
"jms/serializer-bundle": "4.1.0",
"lexik/jwt-authentication-bundle": "^2.18",
"stof/doctrine-extensions-bundle": "1.8.0",
"symfony/dependency-injection": "5.4.5",
"symfony/framework-bundle": "5.4.5 || 6.2.8",
"symfony/validator": "5.4.25 || 6.2.12 || 6.3.1",
"liip/imagine-bundle": "2.7.0"
"symfony/validator": "5.4.25"
},
"require-dev": {
"behat/behat": "^3.6.1",
@ -198,7 +198,7 @@
"consolidation/robo": "^3.0|^4.0",
"dmore/behat-chrome-extension": "^1.3",
"dmore/chrome-mink-driver": "^2.7",
"doctrine/cache": "^1.10",
"doctrine/cache": "^2.2",
"doctrine/data-fixtures": "^1.4",
"friends-of-behat/mink": "^1.8",
"friends-of-behat/mink-browserkit-driver": "^1.4",
@ -214,26 +214,29 @@
"matthiasnoback/symfony-dependency-injection-test": "^4.2",
"mikey179/vfsstream": "^1.6",
"mockery/mockery": "^1.4",
"payum/paypal-express-checkout-nvp": "^1.7.3",
"payum/stripe": "^1.7.3",
"phparkitect/phparkitect": "^0.2.9",
"phpspec/phpspec": "^7.2",
"phpspec/prophecy-phpunit": "^2.0",
"phpstan/phpstan": "^1.6",
"phpstan/phpstan-doctrine": "1.3.2",
"phpstan/phpstan-doctrine": "1.3.43",
"phpstan/phpstan-symfony": "^1.2",
"phpstan/phpstan-webmozart-assert": "^1.1",
"phpunit/phpunit": "^8.5",
"phpunit/phpunit": "^9.5",
"polishsymfonycommunity/symfony-mocker-container": "^1.0",
"psr/event-dispatcher": "^1.0",
"rector/rector": "^0.12.20",
"rector/rector": "^0.18.0",
"robertfausk/behat-panther-extension": "^1.1",
"stripe/stripe-php": "^8.1",
"stripe/stripe-php": "^7.0 || ^8.1",
"sylius-labs/coding-standard": "^4.2",
"sylius-labs/suite-tags-extension": "~0.1",
"symfony/browser-kit": "^5.4 || ^6.0",
"symfony/debug-bundle": "^5.4 || ^6.0",
"symfony/dotenv": "^5.4 || ^6.0",
"symfony/browser-kit": "^5.4.21 || ^6.4",
"symfony/debug-bundle": "^5.4.21 || ^6.4",
"symfony/dotenv": "^5.4.21 || ^6.4",
"symfony/flex": "^2.4",
"symfony/runtime": "^5.4 || ^6.0",
"symfony/web-profiler-bundle": "^5.4 || ^6.0",
"symfony/runtime": "^5.4.21 || ^6.4",
"symfony/web-profiler-bundle": "^5.4.21 || ^6.4",
"symplify/monorepo-builder": "^11.0"
},
"suggest": {
@ -257,11 +260,15 @@
"extra": {
"symfony": {
"allow-contrib": false,
"require": "5.4.*"
"require": "^6.4"
},
"branch-alias": {
"dev-main": "1.13-dev"
}
},
"autoload": {
"psr-4": {
"Sylius\\Abstraction\\StateMachine\\": "src/Sylius/Abstraction/StateMachine/src",
"Sylius\\Behat\\": "src/Sylius/Behat/",
"Sylius\\Bundle\\": "src/Sylius/Bundle/",
"Sylius\\Component\\": "src/Sylius/Component/"
@ -316,7 +323,8 @@
"spec\\Sylius\\Bundle\\TaxationBundle\\": "src/Sylius/Bundle/TaxationBundle/spec/",
"spec\\Sylius\\Bundle\\TaxonomyBundle\\": "src/Sylius/Bundle/TaxonomyBundle/spec/",
"spec\\Sylius\\Bundle\\UiBundle\\": "src/Sylius/Bundle/UiBundle/spec/",
"spec\\Sylius\\Bundle\\UserBundle\\": "src/Sylius/Bundle/UserBundle/spec/"
"spec\\Sylius\\Bundle\\UserBundle\\": "src/Sylius/Bundle/UserBundle/spec/",
"Tests\\Sylius\\Abstraction\\StateMachine\\": "src/Sylius/Abstraction/StateMachine/tests"
},
"classmap": [
"src/Kernel.php"

View file

@ -7,6 +7,7 @@ return [
Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true],
Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true],
Sylius\Calendar\SyliusCalendarBundle::class => ['all' => true],
Sylius\Abstraction\StateMachine\SyliusStateMachineAbstractionBundle::class => ['all' => true],
Sylius\Bundle\OrderBundle\SyliusOrderBundle::class => ['all' => true],
Sylius\Bundle\MoneyBundle\SyliusMoneyBundle::class => ['all' => true],
Sylius\Bundle\CurrencyBundle\SyliusCurrencyBundle::class => ['all' => true],

View file

@ -7,6 +7,8 @@ imports:
- { resource: "@SyliusApiBundle/Resources/config/app/config.yaml" }
- { resource: "../parameters.yaml" }
parameters:
sylius_core.public_dir: '%kernel.project_dir%/public'

View file

@ -0,0 +1,21 @@
services:
# Register nyholm/psr7 services for autowiring with PSR-17 (HTTP factories)
Psr\Http\Message\RequestFactoryInterface: '@nyholm.psr7.psr17_factory'
Psr\Http\Message\ResponseFactoryInterface: '@nyholm.psr7.psr17_factory'
Psr\Http\Message\ServerRequestFactoryInterface: '@nyholm.psr7.psr17_factory'
Psr\Http\Message\StreamFactoryInterface: '@nyholm.psr7.psr17_factory'
Psr\Http\Message\UploadedFileFactoryInterface: '@nyholm.psr7.psr17_factory'
Psr\Http\Message\UriFactoryInterface: '@nyholm.psr7.psr17_factory'
# Register nyholm/psr7 services for autowiring with HTTPlug factories
Http\Message\MessageFactory: '@nyholm.psr7.httplug_factory'
Http\Message\RequestFactory: '@nyholm.psr7.httplug_factory'
Http\Message\ResponseFactory: '@nyholm.psr7.httplug_factory'
Http\Message\StreamFactory: '@nyholm.psr7.httplug_factory'
Http\Message\UriFactory: '@nyholm.psr7.httplug_factory'
nyholm.psr7.psr17_factory:
class: Nyholm\Psr7\Factory\Psr17Factory
nyholm.psr7.httplug_factory:
class: Nyholm\Psr7\Factory\HttplugFactory

View file

@ -1,2 +1,20 @@
parameters:
test_default_state_machine_adapter: 'symfony_workflow'
test_sylius_state_machine_adapter: '%env(string:default:test_default_state_machine_adapter:TEST_SYLIUS_STATE_MACHINE_ADAPTER)%'
sylius_user:
encoder: plaintext
sylius_api:
enabled: true
sylius_state_machine_abstraction:
graphs_to_adapters_mapping:
sylius_catalog_promotion: '%test_sylius_state_machine_adapter%'
sylius_order: '%test_sylius_state_machine_adapter%'
sylius_order_checkout: '%test_sylius_state_machine_adapter%'
sylius_order_payment: '%test_sylius_state_machine_adapter%'
sylius_order_shipping: '%test_sylius_state_machine_adapter%'
sylius_payment: '%test_sylius_state_machine_adapter%'
sylius_product_review: '%test_sylius_state_machine_adapter%'
sylius_shipment: '%test_sylius_state_machine_adapter%'

View file

@ -1,6 +1,3 @@
security:
password_hashers:
Sylius\Component\User\Model\UserInterface:
algorithm: argon2i
time_cost: 3
memory_cost: 10
Sylius\Component\User\Model\UserInterface: plaintext

View file

@ -0,0 +1,2 @@
framework:
workflows: ~

2
config/parameters.yaml Normal file
View file

@ -0,0 +1,2 @@
parameters:
locale: en_US

View file

@ -1,4 +1 @@
# Put parameters here that don't need to change on each machine where the app is deployed
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration
parameters:
locale: en_US

View file

@ -14,7 +14,7 @@ Before working on Sylius, set a Symfony friendly environment up with the followi
software:
* Git
* PHP version 8.0 or above
* PHP version 8.1 or above
* MySQL
Configure Git

View file

@ -8,7 +8,7 @@ Overview
Requirements
------------
We recommend using Node.js ``16.x`` as it is the current LTS version. However, Sylius frontend is also compatible with Node.js ``14.x`` and ``18.x``.
We recommend using Node.js ``20.x`` as it is the current LTS version. However, Sylius frontend is also compatible with Node.js ``18.x``.
In Sylius, we use ``yarn`` as a package manager, but there are no obstacles to using ``npm``.

View file

@ -7,7 +7,7 @@ Installation
The Sylius main application can serve as an end-user app, as well as a foundation
for your custom e-commerce application.
To create your Sylius-based application, first make sure you use PHP 8.0 or higher
To create your Sylius-based application, first make sure you use PHP 8.1 or higher
and have `Composer`_ installed.
Initiating A New Sylius Project
@ -21,7 +21,7 @@ To begin creating your new project, run this command:
.. note::
Make sure to use PHP ^8.0. Using an older PHP version will result in installing an older version of Sylius.
Make sure to use PHP ^8.1. Using an older PHP version will result in installing an older version of Sylius.
This will create a new Symfony project in the ``acme`` directory. Next, move to the project directory:

View file

@ -29,7 +29,7 @@ PHP required modules and configuration
**PHP version**:
+---------------+-----------------------+
| PHP | ^8.0 |
| PHP | ^8.1 |
+---------------+-----------------------+
**PHP extensions**:
@ -62,7 +62,7 @@ Database
By default, the database connection is pre-configured to work with a following MySQL configuration:
+---------------+-----------------------+
| MySQL | 5.7+, 8.0+ |
| MySQL | 8.0+ |
+---------------+-----------------------+
.. note::
@ -73,10 +73,10 @@ NPM Package Manager
-------------------
Sylius Frontend depends on `npm packages <https://docs.npmjs.com/about-npm>`_ for it to run you need to have Node.js installed.
Current minimum supported version of Node.js is:
Current supported versions of Node.js are:
+---------------+-----------------------+
| Node.js | 14.x |
| Node.js | 18.x, 20.x |
+---------------+-----------------------+
Access rights

View file

@ -150,7 +150,7 @@ How to perform the Selecting shipping Step programmatically?
Before approaching this step be sure that your Order is in the ``addressed`` state. In this state your order
will already have a default ShippingMethod assigned, but in this step you can change it and have everything recalculated automatically.
Firstly either create new (see how in the `Shipments concept </book/orders/shipments>`_) or retrieve a **ShippingMethod**
Firstly either create new (see how in the :doc:`Shipments concept </book/orders/shipments>`) or retrieve a **ShippingMethod**
from the repository to assign it to your order's shipment created defaultly in the addressing step.
.. code-block:: php
@ -210,7 +210,7 @@ How to perform the Selecting payment step programmatically?
Before this step your Order should be in the ``shipping_selected`` state. It will have a default Payment selected after the addressing step,
but in this step you can change it.
Firstly either create new (see how in the `Payments concept </book/orders/payments>`_) or retrieve a **PaymentMethod**
Firstly either create new (see how in the :doc:`Payments concept </book/orders/payments>`) or retrieve a **PaymentMethod**
from the repository to assign it to your order's payment created defaultly in the addressing step.
.. code-block:: php

View file

@ -92,16 +92,19 @@ relevant classes, methods, properties:
The deprecation message should indicate the version in which the class/method was
deprecated and how the feature was replaced (whenever possible).
A PHP ``\E_USER_DEPRECATED`` error must also be triggered to help people with
the migration:
A PHP deprecation must also be triggered to help people with
the migration, for instance:
.. code-block:: php
@trigger_error(
'XXX() is deprecated since version 2.X and will be removed in 2.Y. Use XXX instead.',
\E_USER_DEPRECATED
trigger_deprecation(
'sylius/some-package', // package name
'1.x', // package version
'A is deprecated and will be removed in Sylius 2.0. Use B instead.', // message
);
You should not use the @trigger_error() function.
.. _Semantic Versioning: https://semver.org/
.. _Symfony's Backward Compatibility Promise: https://symfony.com/doc/current/contributing/code/bc.html
.. _Symfony's Experimental Features: https://symfony.com/doc/current/contributing/code/experimental.html

View file

@ -38,15 +38,15 @@ That's it! All other files are just a boilerplate to show you what can be done i
* ``src/Controller/GreetingController.php``
* ``src/Resources/config/admin_routing.yml``
* ``config/admin_routing.yml``
* ``src/Resources/config/shop_routing.yml``
* ``config/shop_routing.yml``
* ``src/Resources/public/greeting.js``
* ``public/greeting.js``
* ``src/Resources/views/dynamic_greeting.html.twig``
* ``templates/dynamic_greeting.html.twig``
* ``src/Resources/views/static_greeting.html.twig``
* ``templates/static_greeting.html.twig``
* All files from ``tests/Behat/Page/Shop/`` (with corresponding services)

View file

@ -30,6 +30,7 @@ Configuration reference
customer_group:
classes:
model: Sylius\Component\Customer\Model\CustomerGroup
repository: Sylius\Bundle\CustomerBundle\Doctrine\ORM\CustomerGroupRepository
interface: Sylius\Component\Customer\Model\CustomerGroupInterface
controller: Sylius\Bundle\ResourceBundle\Controller\ResourceController
factory: Sylius\Component\Resource\Factory\Factory

View file

@ -1,13 +1,6 @@
.. rst-class:: outdated
Processors
==========
.. danger::
We're sorry but **this documentation section is outdated**. Please have that in mind when trying to use it.
You can help us making documentation up to date via Sylius Github. Thank you!
Order processors are responsible of manipulating the orders to apply different predefined adjustments or other modifications based on order state.
Registering custom processors
@ -35,6 +28,38 @@ Once you have your own :ref:`component_order_processors_order-processor-interfac
You can add your own processor to the :ref:`component_order_processors_composite_order_processor` using `sylius.order_processor`
.. note::
If services autoconfiguration is enabled, you should register your own processor by adding the ``Sylius\Bundle\OrderBundle\Attribute\AsOrderProcessor`` attribute
on the top of the processor class.
.. code-block:: php
<?php
namespace App\OrderProcessor;
use Sylius\Bundle\OrderBundle\Attribute\AsOrderProcessor;
use Sylius\Component\Order\Model\OrderInterface;
use Sylius\Component\Order\Processor\OrderProcessorInterface;
#[AsOrderProcessor(priority: 10)] //priority is optional
//#[AsOrderProcessor] can be used as well
final class CustomOrderProcessor implements OrderProcessorInterface
{
public function process(OrderInterface $order): void
{
// ...
}
}
Then you should enable autoconfiguring with attributes in your ``config/packages/_sylius.yaml`` file:
.. code-block:: yaml
sylius_order:
autoconfigure_with_attributes: true
Using CompositeOrderProcessor
-----------------------------

View file

@ -74,7 +74,7 @@ In the response you should get a collection with only one item:
],
"translations": {
"en_US": {
"@id": "/api/v2/shop/product-variant-translation/579960",
"@id": "/api/v2/shop/product-variant-translations/579960",
"@type": "ProductVariantTranslation",
"id": 579960,
"name": "S Petite",

View file

@ -0,0 +1,168 @@
Handle multiple channels in CLI
===============================
When we use directly or indirectly any service depending on a channel context, we are not able to define which channel we want to use, when there are more than two.
Your primary goal should be to avoid such cases, but if you have to, there is a way to do it.
What is our goal?
-----------------
We have to create a custom channel context available only from the CLI context. This channel context should allow setting a channel code (which we will do inside the console command). This way, we can use the channel context in our services.
1. Custom Channel Context
-------------------------
First, we need to create a channel context. Let's remind the requirements:
* available only from the CLI
* there must be a way to pass in a channel code
Our suggested solution is the following:
.. code-block:: php
// src/Channel/Context/CliBasedChannelContext.php
<?php
declare(strict_types=1);
namespace App\Channel\Context;
use Sylius\Component\Channel\Context\ChannelNotFoundException;
use Sylius\Component\Channel\Model\ChannelInterface;
use Sylius\Component\Channel\Repository\ChannelRepositoryInterface;
final class CliBasedChannelContext implements CliBasedChannelContextInterface
{
private ?string $channelCode = null;
public function __construct(
private ChannelRepositoryInterface $channelRepository,
) {
}
public function setChannelCode(?string $channelCode): void
{
$this->channelCode = $channelCode;
}
public function getChannelCode(): ?string
{
return $this->channelCode;
}
public function getChannel(): ChannelInterface
{
if ('cli' !== PHP_SAPI || null === $this->channelCode) {
throw new ChannelNotFoundException();
}
$channel = $this->channelRepository->findOneByCode($this->channelCode);
if (null === $channel) {
throw new ChannelNotFoundException();
}
return $channel;
}
}
.. code-block:: php
// src/Channel/Context/CliBasedChannelContextInterface.php;
<?php
declare(strict_types=1);
namespace App\Channel\Context;
use Sylius\Component\Channel\Context\ChannelContextInterface;
interface CliBasedChannelContextInterface extends ChannelContextInterface
{
public function setChannelCode(?string $channelCode): void;
public function getChannelCode(): ?string;
}
Now, we have to configure our custom channel context as a service:
.. code-block:: yaml
# config/services.yaml
services:
App\Channel\Context\CliBasedChannelContextInterface:
class: App\Channel\Context\CliBasedChannelContext
arguments:
- '@sylius.repository.channel'
tags:
- { name: 'sylius.context.channel', priority: -256 }
2. Usage of the new custom channel context in a console command
---------------------------------------------------------------
For our example, we will create a DummyCommand which will take a channel code as an option
and dispatch a dummy event. This event is handled by a subscriber using
the channel context to print the channel's name.
You command might look like this:
.. code-block:: yaml
// src/Console/Command/DummyCommand.php
<?php
declare(strict_types=1);
namespace App\Console\Command;
use App\Channel\Context\CliBasedChannelContextInterface;
use App\Console\Command\Event\DummyEvent; // it is just a dummy event, nothing special there
use Symfony\Component\Console\Attribute\AsCommand;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
#[AsCommand('app:dummy', description: 'Dummy command')]
class DummyCommand extends Command
{
public function __construct (
private CliBasedChannelContextInterface $cliBasedChannelContext,
private EventDispatcherInterface $dispatcher,
) {
parent::__construct();
}
protected function configure(): void
{
$this
->addOption('channel', 'c', InputOption::VALUE_OPTIONAL, 'Channel code')
;
}
protected function execute(InputInterface $input, OutputInterface $output): int
{
if (null !== $channelCode = $input->getOption('channel')) {
$this->cliBasedChannelContext->setChannelCode($channelCode);
}
// The subscriber just gets a channel from the channel context
$this->dispatcher->dispatch(new DummyEvent());
return Command::SUCCESS;
}
}
The output of the example is following:
.. code-block:: bash
$ bin/console app:dummy -c MAGIC_WEB
Hi! I am Dummy Event Subscriber. I am using Channel Context.
Your channel name is: Magic Web Channel
$ bin/console app:dummy -c FASHION_WEB
Hi! I am Dummy Event Subscriber. I am using Channel Context.
Your channel name is: Fashion Web Store

View file

@ -0,0 +1 @@
* :doc:`/cookbook/cli/handle-multiple-channels-in-cli`

View file

@ -3,6 +3,16 @@ The Cookbook
The Sylius Cookbook is a collection of solution articles helping you with some specific, narrow problems.
CLI
---
.. toctree::
:hidden:
cli/handle-multiple-channels-in-cli
.. include:: /cookbook/cli/map.rst.inc
Entities
--------

View file

@ -1,3 +1,4 @@
Customizing Grids
=================
@ -139,6 +140,24 @@ If you would like to change the link to which an action button is redirecting, t
The above grid modification will change the redirect of the ``show`` action to redirect to the shop, instead of admin show.
Also the label was changed here.
How to remove label of an action from a grid?
'''''''''''''''''''''''''''''''''''''''''''''
If you would like to remove label for some actions in any grid, you just need to set its ``labeled`` option to ``false`` like below:
.. code-block:: yaml
# config/packages/_sylius.yaml
sylius_grid:
grids:
sylius_admin_product_review:
actions:
item:
delete:
type: delete
options:
labeled: false
How to modify positions of fields, filters and actions in a grid?
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

View file

@ -127,7 +127,7 @@ and let's take first variant `@id` from list:
],
"translations": {
"en_US": {
"@id": "/api/v2/shop/product-variant-translation/123889",
"@id": "/api/v2/shop/product-variant-translations/123889",
"@type": "ProductVariantTranslation",
"id": 123889,
"name": "S",

View file

@ -11,6 +11,7 @@
declare(strict_types=1);
use PhpCsFixer\Fixer\ClassNotation\OrderedTypesFixer;
use PhpCsFixer\Fixer\ClassNotation\VisibilityRequiredFixer;
use PhpCsFixer\Fixer\Comment\HeaderCommentFixer;
use PhpCsFixer\Fixer\LanguageConstruct\ErrorSuppressionFixer;
@ -22,16 +23,16 @@ return static function (ECSConfig $config): void {
$config->import('vendor/sylius-labs/coding-standard/ecs.php');
$config->parallel();
$config->paths(['src/Sylius']);
$config->paths(['src/Sylius', 'tests']);
$config->skip([
InlineDocCommentDeclarationSniff::class . '.MissingVariable',
InlineDocCommentDeclarationSniff::class . '.NoAssignment',
VisibilityRequiredFixer::class => ['*Spec.php'],
ErrorSuppressionFixer::class => 'src/Sylius/Bundle/CoreBundle/DependencyInjection/Compiler/BackwardsCompatibility/CancelOrderStateMachineCallbackPass.php',
'**/var/*',
'src/Sylius/Behat/Service/Converter/IriConverter.php',
]);
$config->ruleWithConfiguration(PhpdocSeparationFixer::class, ['groups' => [['Given', 'When', 'Then']]]);
$config->ruleWithConfiguration(OrderedTypesFixer::class, ['null_adjustment' => 'always_last']);
$config->ruleWithConfiguration(
HeaderCommentFixer::class,
[

View file

@ -1,348 +0,0 @@
<?php
/**
* @see https://github.com/laminas/laminas-stdlib for the canonical source repository
* @copyright https://github.com/laminas/laminas-stdlib/blob/master/COPYRIGHT.md
* @license https://github.com/laminas/laminas-stdlib/blob/master/LICENSE.md New BSD License
*/
namespace Laminas\Stdlib;
use Countable;
use IteratorAggregate;
use Serializable;
use function array_map;
use function count;
use function get_class;
use function serialize;
use function sprintf;
use function unserialize;
/**
* Re-usable, serializable priority queue implementation
*
* SplPriorityQueue acts as a heap; on iteration, each item is removed from the
* queue. If you wish to re-use such a queue, you need to clone it first. This
* makes for some interesting issues if you wish to delete items from the queue,
* or, as already stated, iterate over it multiple times.
*
* This class aggregates items for the queue itself, but also composes an
* "inner" iterator in the form of an SplPriorityQueue object for performing
* the actual iteration.
*
* @psalm-template T
* @implements IteratorAggregate<int, T>
*/
class PriorityQueue implements Countable, IteratorAggregate, Serializable
{
const EXTR_DATA = 0x00000001;
const EXTR_PRIORITY = 0x00000002;
const EXTR_BOTH = 0x00000003;
/**
* Inner queue class to use for iteration
* @var string
*/
protected $queueClass = SplPriorityQueue::class;
/**
* Actual items aggregated in the priority queue. Each item is an array
* with keys "data" and "priority".
* @var array
*/
protected $items = [];
/**
* Inner queue object
* @var SplPriorityQueue
*/
protected $queue;
/**
* Insert an item into the queue
*
* Priority defaults to 1 (low priority) if none provided.
*
* @param mixed $data
* @param int $priority
* @return PriorityQueue
*
* @psalm-param T $data
* @psalm-return PriorityQueue<T>
*/
public function insert($data, $priority = 1)
{
$priority = (int) $priority;
$this->items[] = [
'data' => $data,
'priority' => $priority,
];
$this->getQueue()->insert($data, $priority);
return $this;
}
/**
* Remove an item from the queue
*
* This is different than {@link extract()}; its purpose is to dequeue an
* item.
*
* This operation is potentially expensive, as it requires
* re-initialization and re-population of the inner queue.
*
* Note: this removes the first item matching the provided item found. If
* the same item has been added multiple times, it will not remove other
* instances.
*
* @param mixed $datum
* @return bool False if the item was not found, true otherwise.
*
* @psalm-param T $datum
*/
public function remove($datum)
{
$found = false;
foreach ($this->items as $key => $item) {
if ($item['data'] === $datum) {
$found = true;
break;
}
}
if ($found) {
unset($this->items[$key]);
$this->queue = null;
if (! $this->isEmpty()) {
$queue = $this->getQueue();
foreach ($this->items as $item) {
$queue->insert($item['data'], $item['priority']);
}
}
return true;
}
return false;
}
/**
* Is the queue empty?
*
* @return bool
*/
public function isEmpty()
{
return (0 === $this->count());
}
/**
* How many items are in the queue?
*
* @return int
*/
public function count()
{
return count($this->items);
}
/**
* Peek at the top node in the queue, based on priority.
*
* @return mixed
*/
public function top()
{
return $this->getIterator()->top();
}
/**
* Extract a node from the inner queue and sift up
*
* @return mixed
*/
public function extract()
{
$value = $this->getQueue()->extract();
$keyToRemove = null;
$highestPriority = null;
foreach ($this->items as $key => $item) {
if ($item['data'] !== $value) {
continue;
}
if (null === $highestPriority) {
$highestPriority = $item['priority'];
$keyToRemove = $key;
continue;
}
if ($highestPriority >= $item['priority']) {
continue;
}
$highestPriority = $item['priority'];
$keyToRemove = $key;
}
if ($keyToRemove !== null) {
unset($this->items[$keyToRemove]);
}
return $value;
}
/**
* Retrieve the inner iterator
*
* SplPriorityQueue acts as a heap, which typically implies that as items
* are iterated, they are also removed. This does not work for situations
* where the queue may be iterated multiple times. As such, this class
* aggregates the values, and also injects an SplPriorityQueue. This method
* retrieves the inner queue object, and clones it for purposes of
* iteration.
*
* @return SplPriorityQueue
*
* @psalm-return SplPriorityQueue<T>
*/
public function getIterator()
{
$queue = $this->getQueue();
return clone $queue;
}
/**
* Serialize the data structure
*
* @return string
*/
public function serialize()
{
return serialize($this->items);
}
/**
* Unserialize a string into a PriorityQueue object
*
* Serialization format is compatible with {@link Laminas\Stdlib\SplPriorityQueue}
*
* @param string $data
* @return void
*/
public function unserialize($data)
{
foreach (unserialize($data) as $item) {
$this->insert($item['data'], $item['priority']);
}
}
/**
* Serialize to an array
*
* By default, returns only the item data, and in the order registered (not
* sorted). You may provide one of the EXTR_* flags as an argument, allowing
* the ability to return priorities or both data and priority.
*
* @param int $flag
* @return array
*/
public function toArray($flag = self::EXTR_DATA)
{
switch ($flag) {
case self::EXTR_BOTH:
return $this->items;
case self::EXTR_PRIORITY:
return array_map(function ($item) {
return $item['priority'];
}, $this->items);
case self::EXTR_DATA:
default:
return array_map(function ($item) {
return $item['data'];
}, $this->items);
}
}
/**
* Specify the internal queue class
*
* Please see {@link getIterator()} for details on the necessity of an
* internal queue class. The class provided should extend SplPriorityQueue.
*
* @param string $class
* @return PriorityQueue
*
* @psalm-return PriorityQueue<T>
*/
public function setInternalQueueClass($class)
{
$this->queueClass = (string) $class;
return $this;
}
/**
* Does the queue contain the given datum?
*
* @param mixed $datum
* @return bool
*
* @psalm-param T $datum
*/
public function contains($datum)
{
foreach ($this->items as $item) {
if ($item['data'] === $datum) {
return true;
}
}
return false;
}
/**
* Does the queue have an item with the given priority?
*
* @param int $priority
* @return bool
*/
public function hasPriority($priority)
{
foreach ($this->items as $item) {
if ($item['priority'] === $priority) {
return true;
}
}
return false;
}
/**
* Get the inner priority queue instance
*
* @throws Exception\DomainException
* @return SplPriorityQueue
*/
protected function getQueue()
{
if (null === $this->queue) {
$this->queue = new $this->queueClass();
if (! $this->queue instanceof \SplPriorityQueue) {
throw new Exception\DomainException(sprintf(
'PriorityQueue expects an internal queue of type SplPriorityQueue; received "%s"',
get_class($this->queue)
));
}
}
return $this->queue;
}
/**
* Add support for deep cloning
*
* @return void
*/
public function __clone()
{
if (null !== $this->queue) {
$this->queue = clone $this->queue;
}
}
}

View file

@ -18,7 +18,7 @@ Feature: Seeing validation messages during address addition
Then I should still be on the address addition page
And I should be notified about 6 errors
@ui @javascript @api
@ui @api
Scenario: The province needs to be selected when the chosen country has at least one stated
When I want to add a new address to my address book
And I specify the address as "Lucifer Morningstar", "Seaside Fwy", "90802", "Los Angeles", "United States", "Arkansas"

View file

@ -13,7 +13,7 @@ Feature: Province field entry stays after validation errors
And I have an address "Lucifer Morningstar", "Seaside Fwy", "90802", "Los Angeles", "United States", "Arkansas" in my address book
And I have an address "Fletcher Ren", "Upper Barkly Street", "3377", "Ararat", "Australia", "Victoria" in my address book
@ui @javascript @api
@ui @api
Scenario: The province name stays after validation error
Given I am editing the address of "Lucifer Morningstar"
When I remove the street
@ -21,7 +21,7 @@ Feature: Province field entry stays after validation errors
Then I should still be on the "Lucifer Morningstar" address edit page
And I should still have "Arkansas" as my specified province
@ui @javascript @api
@ui @api
Scenario: The selected province stays after validation error
Given I am editing the address of "Fletcher Ren"
When I remove the street

View file

@ -6,7 +6,7 @@ Feature: Editing a customer profile
Background:
Given the store operates on a single channel in "United States"
And there is a customer "Francis Underwood" identified by an email "francis@underwood.com" and a password "sylius"
And there is a user "francis@underwood.com" identified by "sylius"
And I am logged in as "francis@underwood.com"
@ui @api
@ -18,17 +18,24 @@ Feature: Editing a customer profile
Then I should be notified that it has been successfully edited
And my name should be "Will Conway"
@ui @email
@ui @email @no-api
Scenario: Changing my email if channel requires verification
When I want to modify my profile
And I specify the customer email as "frank@underwood.com"
And I save my changes
# Then I should be notified that it has been successfully edited
# And I should be notified that the verification email has been sent
Then I should be notified that it has been successfully edited
And I should be notified that the verification email has been sent
And it should be sent to "frank@underwood.com"
And I should not be logged in
@ui
@api @no-ui
Scenario: Changing my email if channel requires verification
When I want to modify my profile
And I specify the customer email as "frank@underwood.com"
And I save my changes
And I should not be logged in
@ui @no-api
Scenario: Changing my email if channel does not require verification
Given "United States" channel has account verification disabled
When I want to modify my profile
@ -38,7 +45,7 @@ Feature: Editing a customer profile
And my account should not be verified
And my email should be "frank@underwood.com"
@api
@api @no-ui
Scenario: Changing my email if channel does not require verification
Given "United States" channel has account verification disabled
When I want to modify my profile

View file

@ -12,8 +12,8 @@ Feature: Viewing orders only from current channel
And the store has a zone "United States + United Kingdom" with code "US + UK"
And this zone has the "United States" country member
And this zone has the "United Kingdom" country member
And the store has a product "Angel T-Shirt" priced at "$100" in "Web-US" channel
And this product is also priced at "£200" in "Web-UK" channel
And the store has a product "Angel T-Shirt" priced at "$100.00" in "Web-US" channel
And this product is also priced at "£200.00" in "Web-UK" channel
And the store ships everywhere for free for all channels
And the store allows paying Offline for all channels
And there is a customer "John Hancock" identified by an email "hancock@superheronope.com" and a password "superPower"

View file

@ -9,11 +9,29 @@ Feature: Receiving a welcoming email after registration
And that channel allows to shop using "English (United States)" and "Polish (Poland)" locales
@ui @email @api
Scenario: Receiving a welcoming email after registration
Scenario: Receiving a welcoming email after registration when channel has disabled registration verification
Given on this channel account verification is not required
When I register with email "ghastly@bespoke.com" and password "suitsarelife"
Then a welcoming email should have been sent to "ghastly@bespoke.com"
Then only one email should have been sent to "ghastly@bespoke.com"
And a welcoming email should have been sent to "ghastly@bespoke.com"
@ui @email @api
Scenario: Receiving an account verification email after registration when channel has enabled registration verification
Given on this channel account verification is required
When I register with email "ghastly@bespoke.com" and password "suitsarelife"
Then only one email should have been sent to "ghastly@bespoke.com"
And a verification email should have been sent to "ghastly@bespoke.com"
But a welcoming email should not have been sent to "ghastly@bespoke.com"
@ui @email @api
Scenario: Receiving a welcoming email after registration in different locale than the default one
Given on this channel account verification is not required
When I register with email "ghastly@bespoke.com" and password "suitsarelife" in the "Polish (Poland)" locale
Then a welcoming email should have been sent to "ghastly@bespoke.com" in "Polish (Poland)" locale
@ui @email @api
Scenario: Receiving a welcoming email after account verification when channel has enabled registration verification
Given on this channel account verification is required
And I register with email "ghastly@bespoke.com" and password "suitsarelife"
When I verify my account using link sent to "ghastly@bespoke.com"
Then a welcoming email should have been sent to "ghastly@bespoke.com"

View file

@ -7,8 +7,23 @@ Feature: Account registration
Background:
Given the store operates on a single channel in "United States"
@ui @api
Scenario: Registering a new account with minimum information
@ui @no-api
Scenario: Registering a new account with minimum information when channel has enabled registration verification
Given on this channel account verification is required
When I want to register a new account
And I specify the first name as "Saul"
And I specify the last name as "Goodman"
And I specify the email as "goodman@gmail.com"
And I specify the password as "heisenberg"
And I confirm this password
And I register this account
Then I should be notified that new account has been successfully created
And I should be on registration thank you page
But I should not be logged in
@api @no-ui
Scenario: Registering a new account with minimum information when channel has enabled registration verification
Given on this channel account verification is required
When I want to register a new account
And I specify the first name as "Saul"
And I specify the last name as "Goodman"
@ -31,6 +46,7 @@ Feature: Account registration
And I register this account
Then I should be notified that new account has been successfully created
And I should be logged in
And I should be on my account dashboard
@ui @api
Scenario: Registering a new account with all details

View file

@ -48,3 +48,13 @@ Feature: Resetting a password
And I confirm my new password as "newp@ssw0rd"
And I reset it
Then I should not be able to change my password again with the same token
@ui @email @api
Scenario: Trying to change my account password with an expired token I received
Given I have already received a resetting password email
But I waited too long, and the token expired
When I follow link on my email to reset my password
And I specify my new password as "newp@ssw0rd"
And I confirm my new password as "newp@ssw0rd"
And I reset it
Then I should not be able to change my password with this token

View file

@ -17,14 +17,14 @@ Feature: Signing in to the store validation
Then I should be notified about bad credentials
And I should not be logged in
@ui
@ui @api
Scenario: Trying to sign in without confirming account
When I register with email "sylius@example.com" and password "sylius"
And I want to log in
And I specify the username as "sylius@example.com"
And I specify the password as "sylius"
And I try to log in
Then I should be notified about disabled account
Then I should be notified about bad credentials
And I should not be logged in
@ui @api

View file

@ -49,7 +49,7 @@ Feature: Verifying account's email address
Scenario: Receiving account verification email after registration
When I register with email "ghastly@bespoke.com" and password "suitsarelife"
Then I should be notified that my account has been created and the verification email has been sent
And 2 emails should be sent to "ghastly@bespoke.com"
And 1 email should be sent to "ghastly@bespoke.com"
But I should not be able to log in as "ghastly@bespoke.com" with "suitsarelife" password
@ui @email @api

View file

@ -1,14 +0,0 @@
@managing_countries
Feature: Country unique code validation
In order to avoid making mistakes when managing countries
As an Administrator
I want to be prevented from adding a new country with an existing code
Background:
Given the store operates in "Norway"
And I am logged in as an administrator
@ui @api
Scenario: Trying to add a new country with used code
When I want to add a new country
Then I should not be able to choose "Norway"

View file

@ -0,0 +1,35 @@
@managing_countries
Feature: Country validation
In order to avoid making mistakes when managing countries
As an Administrator
I want to be prevented from adding a new country with invalid code
Background:
Given the store operates in "Norway"
And I am logged in as an administrator
@ui @api
Scenario: Trying to add a new country with used code
When I want to add a new country
Then I should not be able to choose "Norway"
@api @no-ui
Scenario: Trying to add a new country with invalid code
When I want to add a new country
And I specify the country code as "NJ"
And I try to save my changes
Then I should be notified that the country code is invalid
@api @no-ui
Scenario: Trying to add a new country with alpha-3 code
When I want to add a new country
And I specify the country code as "USA"
And I try to save my changes
Then I should be notified that the country code is invalid
@api @no-ui
Scenario: Trying to add a new country with no code
When I want to add a new country
And I do not specify the country code
And I try to save my changes
Then I should be notified that the country code is required

View file

@ -21,7 +21,7 @@ Feature: Province unique fields validation
Scenario: Trying to add a new province with a taken name
When I want to edit this country
And I add the "Northern Ireland" province with "GB-NI" code
And I try to save changes
And I save my changes
Then I should be notified that province name must be unique
@ui @javascript @api
@ -29,7 +29,7 @@ Feature: Province unique fields validation
When I want to edit this country
And I add the "Scotland" province with "GB-SCO" code
And I add the "Not Scotland" province with "GB-SCO" code
And I try to save changes
And I save my changes
Then I should be notified that all province codes and names within this country need to be unique
@ui @javascript @api
@ -37,5 +37,5 @@ Feature: Province unique fields validation
When I want to edit this country
And I add the "Scotland" province with "GB-SC" code
And I add the "Scotland" province with "GB-SCO" code
And I try to save changes
And I save my changes
Then I should be notified that all province codes and names within this country need to be unique

View file

@ -13,7 +13,7 @@ Feature: Province validation
When I want to create a new province in country "United Kingdom"
And I name the province "Scotland"
But I do not specify the province code
And I try to save changes
And I try to save my changes
Then I should be notified that code is required
And province with name "Scotland" should not be added in this country
@ -22,7 +22,7 @@ Feature: Province validation
When I want to create a new province in country "United Kingdom"
And I specify the province code as "GB-SCT"
But I do not name the province
And I try to save changes
And I try to save my changes
Then I should be notified that name is required
And province with code "GB-SCT" should not be added in this country

View file

@ -8,7 +8,7 @@ Feature: Deleting multiple zones
Given the store has zones "North America", "South America" and "Europe"
And I am logged in as an administrator
@ui @api @mink:chromedriver
@ui @mink:chromedriver @no-api
Scenario: Deleting multiple zones at once
When I browse zones
And I check the "North America" zone

View file

@ -39,7 +39,7 @@ Feature: Being redirected to previous filtered page
And I cancel my changes
Then I should be redirected to the 2nd page of only enabled products
@ui @javascript @no-api
@ui @no-api
Scenario: Being redirected to previous filtered page after cancelling creating a new product
When I browse products
And I choose enabled filter

View file

@ -1,44 +0,0 @@
@admin_dashboard
Feature: Statistics dashboard in a single channel
In order to have an overview of my sales
As an Administrator
I want to see overall statistics on my admin dashboard
Background:
Given the store operates on a single channel in "United States"
And the store ships everywhere for Free
And the store allows paying Offline
And the store has a product "Sylius T-Shirt"
And this product has "Red XL" variant priced at "$40"
And I am logged in as an administrator
@ui
Scenario: Seeing basic statistics for entire store
Given 3 customers have fulfilled 4 orders placed for total of "$8566.00"
And then 2 more customers have paid 2 orders placed for total of "$459.00"
When I open administration dashboard
Then I should see 6 new orders
And I should see 5 new customers
And there should be total sales of "$9,025.00"
And the average order value should be "$1,504.17"
@ui
Scenario: Statistics include only fulfilled orders that were not cancelled
Given 4 customers have fulfilled 4 orders placed for total of "$5241.00"
And then 2 more customers have placed 2 orders for total of "$459.00"
And 2 customers have added products to the cart for total of "$3450.00"
And a single customer has placed an order for total of "$1000.00"
But the customer cancelled this order
When I open administration dashboard
Then I should see 4 new orders
And I should see 9 new customers
And there should be total sales of "$5,241.00"
And the average order value should be "$1,310.25"
@ui
Scenario: Seeing recent orders and customers
Given 2 customers have placed 3 orders for total of "$340.00"
And 2 customers have added products to the cart for total of "$424.00"
When I open administration dashboard
Then I should see 4 new customers in the list
And I should see 3 new orders in the list

View file

@ -1,50 +0,0 @@
@admin_dashboard
Feature: Statistics dashboard per channel
In order to have an overview of my sales
As an Administrator
I want to see overall statistics on my admin dashboard in a specific channel
Background:
Given the store operates on a channel named "Poland"
And there is product "Onion" available in this channel
And the store operates on another channel named "United States"
And there is product "Banana" available in that channel
And the store ships everywhere for Free
And the store allows paying Offline
And I am logged in as an administrator
@ui
Scenario: Seeing basic statistics for the first channel by default
Given 3 customers have fulfilled 4 orders placed for total of "$8566.00" mostly "Onion" product
And then 2 more customers have fulfilled 2 orders placed for total of "$459.00" mostly "Banana" product
When I open administration dashboard
Then I should see 4 new orders
And I should see 5 new customers
And there should be total sales of "$8,566.00"
And the average order value should be "$2,141.50"
@ui
Scenario: Changing channel in administration dashboard
Given 4 customers have fulfilled 4 orders placed for total of "$5241.00" mostly "Onion" product
And then 2 more customers have fulfilled 2 orders placed for total of "$459.00" mostly "Banana" product
And then 2 more customers have placed 3 orders for total of "$1259.00" mostly "Banana" product
When I open administration dashboard
And I choose "United States" channel
Then I should see 2 new orders
And I should see 8 new customers
And there should be total sales of "$459.00"
And the average order value should be "$229.50"
@ui
Scenario: Seeing recent orders in a specific channel
Given 3 customers have placed 4 orders for total of "$8566.00" mostly "Onion" product
And then 2 more customers have placed 2 orders for total of "$459.00" mostly "Banana" product
When I open administration dashboard for "Poland" channel
Then I should see 4 new orders in the list
@ui
Scenario: Seeing recent orders in a specific channel
Given 3 customers have placed 4 orders for total of "$8566.00" mostly "Onion" product
And then 2 more customers have placed 2 orders for total of "$459.00" mostly "Banana" product
When I open administration dashboard for "United States" channel
Then I should see 2 new orders in the list

View file

@ -8,7 +8,7 @@ Feature: Redirecting on login page
Given the store operates on a single channel in "United States"
And I have been logged out from administration
@ui
@ui @no-api
Scenario: Redirecting on login page after being logout
When I try to open administration dashboard
Then I should be on login page

View file

@ -7,11 +7,11 @@ Feature: Securing access to the administration panel after using the back button
Background:
Given the store operates on a single channel in "United States"
And I am logged in as an administrator
And I am on the administration dashboard
@ui @mink:chromedriver @no-api
Scenario: Securing access to administration dashboard after using the back button after logging out
When I log out
When I am on the administration dashboard
And I log out
And I go back one page in the browser
Then I should not see the administration dashboard
And I should be on the login page

View file

@ -0,0 +1,67 @@
@admin_dashboard
Feature: Statistics
In order to gain insight into my sales performance and customers activity
As an Administrator
I want to view comprehensive statistics
Background:
Given the store operates on a single channel in "United States"
And the store ships everywhere for Free
And the store allows paying Offline
And the store has a product "Sylius T-Shirt"
And this product has "Red XL" variant priced at "$40.00"
And I am logged in as an administrator
@ui @no-api
Scenario: Seeing statistics for the current year and default channel when expectations are not specified
Given it is "last day of December last year" now
And 2 new customers have fulfilled 2 orders placed for total of "$1,000.00"
And it is "first day of January this year" now
And 3 new customers have fulfilled 4 orders placed for total of "$2,000.21"
And it is "first day of February this year" now
And 2 more new customers have paid 2 orders placed for total of "$5,000.37"
When I view statistics
Then I should see 5 new customers
And I should see 6 paid orders
And there should be total sales of "$7,000.58"
And the average order value should be "$1,166.76"
@api @ui @javascript
Scenario: Seeing statistics for the previous year
Given it is "first day of January last year" now
And 3 new customers have fulfilled 2 orders placed for total of "$2,000.00"
And it is "first day of February this year" now
And 4 more new customers have paid 5 orders placed for total of "$5,000.37"
And 2 more new customers have paid 2 orders placed for total of "$5,000.37"
When I view statistics for "United States" channel and previous year split by month
Then I should see 3 new customers
And I should see 2 paid orders
And there should be total sales of "$2,000.00"
And the average order value should be "$1,000.00"
@ui @javascript @no-api
Scenario: Seeing statistics for the next year
Given it is "first day of January last year" now
And 3 new customers have fulfilled 2 orders placed for total of "$2,000.00"
And it is "first day of February this year" now
And 4 more new customers have paid 5 orders placed for total of "$5,000.37"
And 2 more new customers have paid 2 orders placed for total of "$5,000.37"
When I view statistics for "United States" channel and previous year split by month
And I view statistics for "United States" channel and next year split by month
Then I should see 6 new customers
And I should see 7 paid orders
And there should be total sales of "$10,000.74"
And the average order value should be "$1,428.68"
@api @ui @javascript
Scenario: Seeing statistics that include only fulfilled orders that were not cancelled
Given 4 new customers have fulfilled 4 orders placed for total of "$5,241.00"
And 2 more new customers have placed 2 orders for total of "$459.00"
And 2 new customers have added products to the cart for total of "$3,450.00"
And a single customer has placed an order for total of "$1,000.00"
But the customer cancelled this order
When I view statistics for "United States" channel and current year split by month
Then I should see 4 paid orders
And I should see 9 new customers
And there should be total sales of "$5,241.00"
And the average order value should be "$1,310.25"

View file

@ -0,0 +1,62 @@
@admin_dashboard
Feature: Statistics for a specific channel
In order to gain insight into my sales performance and customers activity in a specific channel
As an Administrator
I want to view comprehensive statistics
Background:
Given the store operates on a channel named "WEB-POLAND"
And there is product "Onion" available in this channel
And the store operates on another channel named "WEB-US"
And there is product "Banana" available in that channel
And the store ships everywhere for Free
And the store allows paying Offline
And I am logged in as an administrator
@ui @no-api
Scenario: Seeing basic statistics for the first channel by default
Given 3 new customers have fulfilled 4 orders placed for total of "$8,566.00" mostly "Onion" product
And 2 more new customers have fulfilled 2 orders placed for total of "$459.00" mostly "Banana" product
When I view statistics
Then I should see 4 paid orders
And I should see 5 new customers
And there should be total sales of "$8,566.00"
And the average order value should be "$2,141.50"
@ui @mink:chromedriver @api
Scenario: Switching to the channel with only fulfilled orders
Given 4 new customers have fulfilled 4 orders placed for total of "$5,241.00" mostly "Onion" product
And 2 more new customers have fulfilled 2 orders placed for total of "$459.00" mostly "Banana" product
And 2 more new customers have placed 3 orders for total of "$1,259.00" mostly "Banana" product
When I view statistics for "WEB-POLAND" channel and current year split by month
And I choose "WEB-US" channel
Then I should see 2 paid orders
And I should see 8 new customers
And there should be total sales of "$459.00"
And the average order value should be "$229.50"
@ui @mink:chromedriver @api
Scenario: Switching to the channel with both fulfilled and placed orders
Given 4 new customers have fulfilled 4 orders placed for total of "$5,241.00" mostly "Onion" product
And 2 more new customers have fulfilled 2 orders placed for total of "$459.00" mostly "Banana" product
And 2 more new customers have placed 3 orders for total of "$1,259.00" mostly "Banana" product
When I view statistics for "WEB-US" channel
And I choose "WEB-POLAND" channel
Then I should see 4 paid orders
And I should see 8 new customers
And there should be total sales of "$5,241.00"
And the average order value should be "$1,310.25"
@no-api @ui
Scenario: Seeing recent orders in a specific channel
Given 3 new customers have placed 4 orders for total of "$8,566.00" mostly "Onion" product
And 2 more new customers have placed 2 orders for total of "$459.00" mostly "Banana" product
When I view statistics for "WEB-POLAND" channel
Then I should see 4 new orders in the list
@no-api @ui
Scenario: Seeing recent orders in a specific channel
Given 3 new customers have placed 4 orders for total of "$8,566.00" mostly "Onion" product
And 2 more new customers have placed 2 orders for total of "$459.00" mostly "Banana" product
When I view statistics for "WEB-US" channel
Then I should see 2 new orders in the list

View file

@ -6,8 +6,8 @@ Feature: Adding a simple product with discounted catalog price to the cart
Background:
Given the store operates on a single channel in "United States"
And the store has a product "Mug" priced at "$40"
And the store has a product "T-Shirt" priced at "$20"
And the store has a product "Mug" priced at "$40.00"
And the store has a product "T-Shirt" priced at "$20.00"
And there is a catalog promotion "Winter sale" that reduces price by "25%" and applies on "T-Shirt" variant
@ui @api
@ -23,7 +23,7 @@ Feature: Adding a simple product with discounted catalog price to the cart
@ui @api
Scenario: Adding a simple product with catalog and cart promotion to the cart
Given there is a promotion "Cheap Stuff"
And this promotion gives "50%" off on every product when the item total is at least "$5"
And this promotion gives "50%" off on every product when the item total is at least "$5.00"
When I add product "T-Shirt" to the cart
And I add product "Mug" to the cart
Then I should be on my cart summary page

View file

@ -6,12 +6,12 @@ Feature: Adding a product with selected option to the cart
Background:
Given the store operates on a single channel in "United States"
And the store has a product "T-Shirt banana"
And this product has option "Size" with values "S" and "M"
And this product has all possible variants
@ui @api
Scenario: Adding a product with single option to the cart
Given the store has a product "T-Shirt banana"
And this product has option "Size" with values "S" and "M"
And this product has all possible variants
When I add "T-Shirt banana" with Size "M" to the cart
Then I should be on my cart summary page
And I should be notified that the product has been successfully added

View file

@ -7,11 +7,11 @@ Feature: Adding a product with selected variant with discounted catalog price to
Background:
Given the store operates on a single channel in "United States"
And the store has a "T-Shirt" configurable product
And the product "T-Shirt" has a "PHP T-Shirt" variant priced at "$20"
And the product "T-Shirt" has a "Kotlin T-Shirt" variant priced at "$400"
And the product "T-Shirt" has a "PHP T-Shirt" variant priced at "$20.00"
And the product "T-Shirt" has a "Kotlin T-Shirt" variant priced at "$400.00"
And the store has a "Keyboard" configurable product
And the product "Keyboard" has a "RGB Keyboard" variant priced at "$40"
And the product "Keyboard" has a "Pink Keyboard" variant priced at "$40"
And the product "Keyboard" has a "RGB Keyboard" variant priced at "$40.00"
And the product "Keyboard" has a "Pink Keyboard" variant priced at "$40.00"
And there is a catalog promotion "Winter sale" that reduces price by "25%" and applies on "PHP T-Shirt" variant
@ui @api

View file

@ -172,20 +172,3 @@ Feature: Allowing access only for correctly logged in users
And the customer has product "Stark T-Shirt" in the cart
And the customer logged out
Then the visitor has no access to change product "Stark T-Shirt" quantity to 2 in the customer cart
@api
Scenario: Accessing to the customers cart by the admin
Given the customer logged in
And the customer has product "Stark T-Shirt" in the cart
And the customer logged out
And there is logged in the administrator
When the administrator try to see the summary of customer's cart
Then the administrator should see "Stark T-Shirt" product with quantity 1 in the customer cart
@api
Scenario: Accessing to the visitors cart by the admin
Given there is the visitor
And the visitor has product "Stark T-Shirt" in the cart
And there is logged in the administrator
When the administrator try to see the summary of customer's cart
Then the administrator should see "Stark T-Shirt" product with quantity 1 in the visitor cart

View file

@ -8,7 +8,7 @@ Feature: Clearing cart after logging out
Given the store operates on a single channel in "United States"
And the store has a product "Stark T-Shirt" priced at "$12.00"
@ui
@ui @no-api
Scenario: Clearing cart after logging out
Given I am a logged in customer
And I have product "Stark T-Shirt" in the cart
@ -16,14 +16,14 @@ Feature: Clearing cart after logging out
And I see the summary of my cart
Then my cart should be empty
@api
@api @no-ui
Scenario: Clearing cart after logging out
Given I am a logged in customer
And I have product "Stark T-Shirt" in the cart
When I log out
Then I should not have access to the summary of my previous cart
@api
@api @no-ui
Scenario: Blocking access to cart if logged user did any action over it (what can be treated as signing it)
Given there is a user "john@snow.com"
When I add this product to the cart

View file

@ -8,7 +8,7 @@ Feature: Viewing a cart summary with the correct default shipping method
Given the store operates on a single channel in "United States"
And the store allows shipping with "Method 1" at position 2 with "$5.00" fee
And the store also allows shipping with "Method 2" at position 0 with "$6.00" fee
And the store has a product "T-Shirt banana" priced at "$10"
And the store has a product "T-Shirt banana" priced at "$10.00"
@ui @api
Scenario:

View file

@ -10,19 +10,20 @@ Feature: Adding a new channel
And the store operates in "United States" and "Poland"
And I am logged in as an administrator
@ui @api
@api @ui
Scenario: Adding a new channel
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile channel"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I add it
Then I should be notified that it has been successfully created
And the channel "Mobile channel" should appear in the registry
@ui @api
@api @ui
Scenario: Adding a new channel with additional fields
When I want to create a new channel
And I specify its code as "MOBILE"
@ -33,6 +34,7 @@ Feature: Adding a new channel
And I set its contact phone number as "11331122"
And I define its color as "blue"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I choose "United States" and "Poland" as operating countries
And I select the "Order items based" as tax calculation strategy

View file

@ -0,0 +1,79 @@
@managing_channels
Feature: Specifying the lowest price for discounted products checking period while creating a channel
In order to show lowest prices only from a specific period
As an Administrator
I want to add a new channel with the lowest price for discounted products checking period
Background:
Given the store has currency "Euro"
And the store has locale "English (United States)"
And the store operates in "United States" and "Poland"
And I am logged in as an administrator
@api @ui
Scenario: Adding a new channel without specifying the lowest price for discounted products checking period
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I add it
Then I should be notified that it has been successfully created
And the "Mobile" channel should have the lowest price for discounted products checking period set to 30 days
@api @ui
Scenario: Adding a new channel with a specified lowest price for discounted products checking period
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I specify 15 days as the lowest price for discounted products checking period
And I add it
Then I should be notified that it has been successfully created
And the "Mobile" channel should have the lowest price for discounted products checking period set to 15 days
@api @ui
Scenario: Being prevented from creating a new channel with the lowest price for discounted products checking period equal to zero
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I specify 0 days as the lowest price for discounted products checking period
And I try to add it
Then I should be notified that the lowest price for discounted products checking period must be greater than 0
@api @ui
Scenario: Being prevented from creating a new channel with a negative lowest price for discounted products checking period
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I disable showing the lowest price of discounted products
And I specify -10 days as the lowest price for discounted products checking period
And I try to add it
Then I should be notified that the lowest price for discounted products checking period must be greater than 0
@api @ui
Scenario: Being prevented from creating a new channel with a too big lowest price for discounted products checking period
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I disable showing the lowest price of discounted products
And I specify 99999999999 days as the lowest price for discounted products checking period
And I try to add it
Then I should be notified that the lowest price for discounted products checking period must be lower

View file

@ -10,12 +10,13 @@ Feature: Adding a new channel with shop billing data
And the store operates in "United States"
And I am logged in as an administrator
@ui @api
@api @ui
Scenario: Adding a new channel with shop billing data
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile channel"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I specify company as "Ragnarok"

View file

@ -0,0 +1,52 @@
@managing_channels
Feature: Choosing whether to show the lowest product price or not while creating a channel
In order to show the lowest price before the product has been discounted only for certain channels
As an Administrator
I want to add a new channel that has this feature enabled or not
Background:
Given the store has currency "Euro"
And the store has locale "English (United States)"
And the store operates in "United States" and "Poland"
And I am logged in as an administrator
@api @ui
Scenario: Adding a new channel with lowest price before the product has been discounted enabled by default
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I add it
Then I should be notified that it has been successfully created
And the "Mobile" channel should have the lowest price of discounted products prior to the current discount enabled
@api @ui
Scenario: Adding a new channel with lowest price before the product has been discounted enabled
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I enable showing the lowest price of discounted products
And I add it
Then I should be notified that it has been successfully created
And the "Mobile" channel should have the lowest price of discounted products prior to the current discount enabled
@api @ui
Scenario: Adding a new channel with lowest price before the product has been discounted disabled
When I want to create a new channel
And I specify its code as "MOBILE"
And I name it "Mobile"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I disable showing the lowest price of discounted products
And I add it
Then I should be notified that it has been successfully created
And the "Mobile" channel should have the lowest price of discounted products prior to the current discount disabled

View file

@ -17,6 +17,7 @@ Feature: Adding a new channel with menu taxon
And I specify its code as "MOBILE"
And I name it "Mobile channel"
And I choose "Euro" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I specify menu taxon as "Clothes"

View file

@ -9,7 +9,7 @@ Feature: Browsing channels
And the store operates on another channel named "Mobile Channel"
And I am logged in as an administrator
@ui @api
@api @ui
Scenario: Browsing defined channels
When I want to browse channels
Then I should see 2 channels in the list

View file

@ -8,7 +8,7 @@ Feature: Channel unique code validation
Given the store operates on a channel identified by "WEB" code
And I am logged in as an administrator
@ui
@api @ui
Scenario: Trying to add channel with taken code
When I want to create a new channel
And I specify its code as "WEB"

View file

@ -7,7 +7,7 @@ Feature: Channel validation
Background:
Given I am logged in as an administrator
@ui
@api @ui
Scenario: Trying to add a new channel without specifying its code
When I want to create a new channel
And I name it "Mobile channel"
@ -16,7 +16,7 @@ Feature: Channel validation
Then I should be notified that code is required
And channel with name "Mobile channel" should not be added
@ui
@api @ui
Scenario: Trying to add a new channel without specifying its name
When I want to create a new channel
And I specify its code as "MOBILE"
@ -25,7 +25,7 @@ Feature: Channel validation
Then I should be notified that name is required
And channel with code "MOBILE" should not be added
@ui
@api @ui
Scenario: Trying to add a new channel without base currency
When I want to create a new channel
And I specify its code as "MOBILE"
@ -34,7 +34,7 @@ Feature: Channel validation
Then I should be notified that base currency is required
And channel with code "MOBILE" should not be added
@ui
@api @ui
Scenario: Trying to add a new channel without default locale
When I want to create a new channel
And I specify its code as "MOBILE"
@ -43,7 +43,7 @@ Feature: Channel validation
Then I should be notified that default locale is required
And channel with code "MOBILE" should not be added
@ui
@api @ui
Scenario: Trying to remove name from existing channel
Given the store operates on a channel named "Web Channel"
When I want to modify this channel

View file

@ -14,6 +14,7 @@ Feature: Choosing a required address in the checkout for a channel
And I specify its code as "MOBILE"
And I name it "Mobile Store"
And I choose "USD" as the base currency
And I make it available in "English (United States)"
And I choose "English (United States)" as a default locale
And I select the "Order items based" as tax calculation strategy
And I choose shipping address as a required address in the checkout

View file

@ -9,7 +9,7 @@ Feature: Deleting a channel
And the store operates on another channel named "Mobile Store"
And I am logged in as an administrator
@ui
@api @ui
Scenario: Deleted channel should disappear from the registry
When I delete channel "Web Store"
Then I should be notified that it has been successfully deleted

Some files were not shown because too many files have changed in this diff Show more