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

25 行
735B

  1. <?php
  2. namespace Lc\CaracoleBundle\Factory\User;
  3. use App\Entity\User\UserPointSale;
  4. use Lc\CaracoleBundle\Container\User\UserPointSaleContainer;
  5. use Lc\CaracoleBundle\Model\PointSale\PointSaleInterface;
  6. use Lc\CaracoleBundle\Model\User\UserPointSaleInterface;
  7. use Lc\SovBundle\Factory\AbstractFactory;
  8. use Lc\SovBundle\Model\User\UserInterface;
  9. class UserPointSaleFactory extends AbstractFactory
  10. {
  11. public function create(UserInterface $user, PointSaleInterface $pointSale): UserPointSaleInterface
  12. {
  13. $class = UserPointSaleContainer::getEntityFqcn();
  14. $userPointSale = new $class;
  15. $userPointSale->setUser($user);
  16. $userPointSale->setPointSale($pointSale);
  17. return $userPointSale;
  18. }
  19. }