Files
kupshop/bundles/KupShop/OrderDiscountBundle/Tests/OrderTestDiscountTrait.php
2025-08-02 16:30:27 +02:00

21 lines
454 B
PHP

<?php
namespace KupShop\OrderDiscountBundle\Tests;
trait OrderTestDiscountTrait
{
/**
* @return \Doctrine\DBAL\Driver\Statement|int
*
* @throws Exception
*/
protected function activateDiscount(array $ids)
{
return sqlQueryBuilder()
->update('order_discounts')
->directValues(['active' => 'Y'])
->where(\Query\Operator::inIntArray($ids, 'id'))
->execute();
}
}