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.

12345678910111213141516171819202122232425
  1. <?php
  2. namespace backend\controllers;
  3. use yii ;
  4. use common\models\Etablissement ;
  5. class BackendController extends \yii\web\Controller
  6. {
  7. public function beforeAction($event)
  8. {
  9. if(!Yii::$app->user->isGuest &&
  10. (Yii::$app->user->identity->etatPaiementEtablissement() == Etablissement::PAIEMENT_ESSAI_TERMINE ||
  11. Yii::$app->user->identity->etatPaiementEtablissement() == Etablissement::PAIEMENT_RETARD))
  12. {
  13. $this->redirect(['paiement/index']) ;
  14. }
  15. return parent::beforeAction($event);
  16. }
  17. }
  18. ?>