Sylius\Behat\Context\Setup\PromotionContext::itGivesFixedDiscountToEveryOrderWithItemsTotalAtLeast PHP Method

itGivesFixedDiscountToEveryOrderWithItemsTotalAtLeast() public method

public itGivesFixedDiscountToEveryOrderWithItemsTotalAtLeast ( Sylius\Component\Core\Model\PromotionInterface $promotion, $discount, $targetAmount )
$promotion Sylius\Component\Core\Model\PromotionInterface
    public function itGivesFixedDiscountToEveryOrderWithItemsTotalAtLeast(PromotionInterface $promotion, $discount, $targetAmount)
    {
        $channelCode = $this->sharedStorage->get('channel')->getCode();
        $rule = $this->ruleFactory->createItemTotal($channelCode, $targetAmount);
        $this->createFixedPromotion($promotion, $discount, [], $rule);
    }
PromotionContext