You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

MerchantSolver.php 478B

123456789101112131415161718192021
  1. <?php
  2. namespace Lc\CaracoleBundle\Solver\Merchant;
  3. use Lc\CaracoleBundle\Model\Merchant\MerchantInterface;
  4. class MerchantSolver
  5. {
  6. public function getNewsletters(MerchantInterface $merchant): array
  7. {
  8. $newsletterArray = [];
  9. foreach($merchant->getSections() as $section) {
  10. foreach($section->getNewsletters() as $newsletter) {
  11. $newsletterArray[] = $newsletter;
  12. }
  13. }
  14. return $newsletterArray;
  15. }
  16. }