Schedule your prices
This plugin propose to schedule the price of a product. Just set the price and a startTime
-
Run
composer require tdevos/sylius-price-evolve-plugin
-
Add
Tdevos\SyliusPriceEvolvePlugin\SyliusPriceEvolvePlugin::class => ['all' => true]
to yourbundle.php
-
Create a file
config/packages/pricing_extension.yaml
services:
app.form.extension.type.channelpriceType:
class: Tdevos\SyliusPriceEvolvePlugin\Form\Extension\PricingsExtension
tags:
- { name: form.type_extension, extended_type: Sylius\Bundle\CoreBundle\Form\Type\Product\ChannelPricingType, priority: 10 }
- Add this trait to
src/Entity/Channel/ChannelPricing.php
class ChannelPricing extends BaseChannelPricing
{
use PluginChannelPricing;
}
- Enjoy !