您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

27 行
787B

  1. <?php
  2. namespace Lc\CaracoleBundle\Factory\Reduction;
  3. use App\Entity\Reduction\ReductionCatalog;
  4. use Lc\CaracoleBundle\Container\Reduction\ReductionCatalogContainer;
  5. use Lc\CaracoleBundle\Model\Merchant\MerchantInterface;
  6. use Lc\CaracoleBundle\Model\Reduction\ReductionCatalogInterface;
  7. use Lc\SovBundle\Factory\AbstractFactory;
  8. class ReductionCatalogFactory extends AbstractFactory
  9. {
  10. public function create(MerchantInterface $merchant, int $status = 1): ReductionCatalogInterface
  11. {
  12. $class = ReductionCatalogContainer::getEntityFqcn();
  13. $reductionCatalog = new $class;
  14. $reductionCatalog->setIsDisplayed(true);
  15. $reductionCatalog->setMerchant($merchant);
  16. $reductionCatalog->setStatus($status);
  17. return $reductionCatalog;
  18. }
  19. }