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.

_button_producer_signup.php 1.0KB

12345678910111213141516171819202122
  1. <?php
  2. $producerManager = $this->getProducerModule()->getManager();
  3. $producerSignupRemainingPlaces = $producerManager->getProducerSignupRemainingPlaces();
  4. if (Yii::$app->user->isGuest): ?>
  5. <?php if($producerManager->isProducerSignupOpen()): ?>
  6. <a class="btn btn-primary"
  7. href="<?= \Yii::$app->urlManagerFrontend->createUrl(['site/signup']); ?>">
  8. <span class="glyphicon glyphicon-user"></span> Je crée mon espace producteur
  9. </a><br />
  10. <?php if($producerManager->getMaximumNumberProducers()): ?>
  11. <strong><?= ($producerSignupRemainingPlaces); ?></strong>
  12. place<?php if($producerSignupRemainingPlaces > 1): ?>s<?php endif; ?> restante<?php if($producerSignupRemainingPlaces > 1): ?>s<?php endif; ?>
  13. <?php endif; ?>
  14. <?php else: ?>
  15. <div class="label label-warning label-producer-signup-closed">
  16. La plateforme n'accueille pas de nouveaux producteurs pour le moment
  17. </div>
  18. <?php endif; ?>
  19. <br />
  20. <br />
  21. <?php endif; ?>