|
|
@@ -13,8 +13,8 @@ $userCurrent = GlobalParam::getCurrentUser(); |
|
|
|
|
|
|
|
$isUserCurrentGrantedAsProducer = $userModule->getAuthorizationChecker()->isGrantedAsProducer($userCurrent); |
|
|
|
$producer = null; |
|
|
|
if ($isUserCurrentGrantedAsProducer) { |
|
|
|
$producer = $producerModule->getRepository()->findOneProducerById(\Yii::$app->user->identity->id_producer); |
|
|
|
if ($isUserCurrentGrantedAsProducer && $userCurrent->id_producer) { |
|
|
|
$producer = $producerModule->getRepository()->findOneProducerById($userCurrent->id_producer); |
|
|
|
} |
|
|
|
|
|
|
|
?> |