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

SectionSolver.php 467B

12345678910111213141516171819202122
  1. <?php
  2. namespace Lc\CaracoleBundle\Solver\Section;
  3. use Lc\CaracoleBundle\Model\Section\SectionInterface;
  4. class SectionSolver
  5. {
  6. // @TODO : à voir si pertinent
  7. public function getNewsletter(SectionInterface $section)
  8. {
  9. $newsletters = $section->getNewsletters();
  10. foreach ($newsletters as $newsletter) {
  11. if ($newsletter->getIsMain()) {
  12. return $newsletter;
  13. }
  14. }
  15. return false;
  16. }
  17. }