Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

26 rindas
790B

  1. <?php
  2. namespace Lc\SovBundle\Factory\Setting;
  3. use App\Entity\Setting\SiteSetting;
  4. use Lc\SovBundle\Factory\AbstractFactory;
  5. use Lc\SovBundle\Model\File\FileInterface;
  6. use Lc\SovBundle\Model\Setting\SiteSettingInterface;
  7. use Lc\SovBundle\Model\Site\SiteInterface;
  8. class SiteSettingFactory extends AbstractFactory implements SiteSettingFactoryInterface
  9. {
  10. public function create(SiteInterface $site, string $name, string $text = null, \DateTime $date = null, FileInterface $file = null): SiteSettingInterface
  11. {
  12. $siteSetting = new SiteSetting();
  13. $siteSetting->setSite($site);
  14. $siteSetting->setName($name);
  15. $siteSetting->setText($text);
  16. $siteSetting->setDate($date);
  17. $siteSetting->setFile($file);
  18. return $siteSetting;
  19. }
  20. }