Browse Source

Correctif

refactoring
Guillaume Bourgeois 1 year ago
parent
commit
84ce4bbd6b
2 changed files with 3 additions and 2 deletions
  1. +1
    -1
      frontend/controllers/SiteController.php
  2. +2
    -1
      producer/controllers/OrderController.php

+ 1
- 1
frontend/controllers/SiteController.php View File



if ($signupForm->load($this->getRequest()->post()) if ($signupForm->load($this->getRequest()->post())
&& ($user = $signupForm->signup()) && ($user = $signupForm->signup())
&& $this->getUserCurrent()->login($user)) {
&& Yii::$app->user->login($user)) {


$this->redirect($returnUrl); $this->redirect($returnUrl);
} }

+ 2
- 1
producer/controllers/OrderController.php View File

{ {
$userProducerManager = $this->getUserProducerManager(); $userProducerManager = $this->getUserProducerManager();
$producerManager = $this->getProducerManager(); $producerManager = $this->getProducerManager();
$user = GlobalParam::getCurrentUser(); $user = GlobalParam::getCurrentUser();
if($user) { if($user) {
$userProducer = $userProducerManager->findOneUserProducer($user, $producer); $userProducer = $userProducerManager->findOneUserProducer($user, $producer);
if (!$userProducer) { if (!$userProducer) {

Loading…
Cancel
Save