vldmr-k / sylius-viewed-products-plugin
Installs: 234
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 2
Type:sylius-plugin
Requires
- php: ^8.0
- sylius/mailer-bundle: ^1.8 || ^2.0@beta
- sylius/sylius: ^1.12
- symfony/webpack-encore-bundle: ^1.15
Requires (Dev)
- behat/behat: ^3.6.1
- behat/mink-selenium2-driver: ^1.4
- dmore/behat-chrome-extension: ^1.3
- dmore/chrome-mink-driver: ^2.7
- friends-of-behat/mink: ^1.8
- friends-of-behat/mink-browserkit-driver: ^1.4
- friends-of-behat/mink-debug-extension: ^2.0.0
- friends-of-behat/mink-extension: ^2.4
- friends-of-behat/page-object-extension: ^0.3
- friends-of-behat/suite-settings-extension: ^1.0
- friends-of-behat/symfony-extension: ^2.1
- friends-of-behat/variadic-extension: ^1.3
- phpspec/phpspec: ^7.2
- phpstan/extension-installer: ^1.0
- phpstan/phpstan: ^1.8.1
- phpstan/phpstan-doctrine: 1.3.43
- phpstan/phpstan-strict-rules: ^1.3.0
- phpstan/phpstan-webmozart-assert: ^1.2.0
- phpunit/phpunit: ^9.5
- polishsymfonycommunity/symfony-mocker-container: ^1.0
- sylius-labs/coding-standard: ^4.2
- symfony/browser-kit: ^5.4 || ^6.0
- symfony/debug-bundle: ^5.4 || ^6.0
- symfony/dotenv: ^5.4 || ^6.0
- symfony/flex: ^2.2.2
- symfony/intl: ^5.4 || ^6.0
- symfony/web-profiler-bundle: ^5.4 || ^6.0
- vimeo/psalm: 5.9.0
Conflicts
- symfony/framework-bundle: 6.2.8
This package is auto-updated.
Last update: 2024-11-20 12:28:12 UTC
README
It's plugin show customers last viewed products.
This simple plugins helps your customers compare and looking the best product for themself
How to install?
composer require vldmr-k/sylius-viewed-products-plugin
Import config file into _sylius.yml
imports: .... - { resource: "@VldmrkSyliusViewedProductsPlugin/Resources/config/config.yml" }
By default, this plugins render last viewed products on product show page, event block name sylius.shop.product.show.content
.
If you want to add this block to another page, add this code to block events which you want
sylius_ui: events: sylius.shop.product.show.content: # <--- default blocks: viewed_products: template: "@VldmrkSyliusViewedProductsPlugin/_viewed_products.html.twig" priority: 20
Storage
By default, this plugins storage ids of viewed products in sylius.storage.session
.
If you want to implement your own storage, you need to implement interface Sylius\Component\Resource\Storage\StorageInterface
,
and override default storage, that to pass to vldmrk.viewed_product.storage.product_viewed_storage
arguments custom storage.
That's all :)
Development
See FORDEVREADME.md