|
|
@@ -81,7 +81,7 @@ if (!Yii::$app->user->isGuest) { |
|
|
|
<section id="section-user-top"> |
|
|
|
<nav class="navbar navbar-default"> |
|
|
|
<div class="container"> |
|
|
|
<?php if ($userManager->isCurrentProducer()): ?> |
|
|
|
<?php if ($userManager->isCurrentProducer() && false): ?> |
|
|
|
<div class="navbar-header"> |
|
|
|
<span class="producer-panel<?php if (!$producerUser->logo): ?> without-logo<?php endif; ?>"> |
|
|
|
<?php if ($producerUser->logo): ?> |
|
|
@@ -107,18 +107,26 @@ if (!Yii::$app->user->isGuest) { |
|
|
|
'url' => $this->getUrlManagerBackend()->createAbsoluteUrl(['site/index']), |
|
|
|
'visible' => $userManager->isCurrentProducer() |
|
|
|
], |
|
|
|
/*[ |
|
|
|
[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-search"></span> Producteurs', |
|
|
|
'url' => $this->getUrlManagerFrontend()->createAbsoluteUrl(['site/producers']), |
|
|
|
'visible' => true |
|
|
|
],*/ |
|
|
|
'visible' => !$userManager->isCurrentProducer() |
|
|
|
], |
|
|
|
[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-user"></span> ' . ((!Yii::$app->user->isGuest) ? Html::encode(Yii::$app->user->identity->name . ' ' . strtoupper(substr(Yii::$app->user->identity->lastname, 0, 1))) : '') . '. ', |
|
|
|
'options' => ['id' => 'label1'], |
|
|
|
'url' => '#', |
|
|
|
'items' => [ |
|
|
|
/*[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-search"></span> Producteurs', |
|
|
|
'url' => $this->getUrlManagerFrontend()->createUrl(['site/producers']), |
|
|
|
],*/ |
|
|
|
[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-chevron-left"></span> Retour à l\'accueil', |
|
|
|
'url' => $this->getUrlManagerFrontend()->createUrl(['site/index']), |
|
|
|
], |
|
|
|
[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-user"></span> Profil', |
|
|
|
'label' => '<span class="glyphicon glyphicon-user"></span> Mon profil', |
|
|
|
'url' => $this->getUrlManagerFrontend()->createUrl(['user/update']), |
|
|
|
], |
|
|
|
[ |
|
|
@@ -175,7 +183,6 @@ echo Nav::widget([ |
|
|
|
], |
|
|
|
'visible' => \Yii::$app->user->isGuest |
|
|
|
], |
|
|
|
|
|
|
|
[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-menu-hamburger"></span>', |
|
|
|
'options' => ['id' => 'label1'], |
|
|
@@ -293,12 +300,12 @@ echo Nav::widget([ |
|
|
|
'url' => $this->getUrlManagerProducer()->createUrl(['site/contact']), |
|
|
|
'active' => $this->getControllerAction() == 'site/contact', |
|
|
|
], |
|
|
|
[ |
|
|
|
/*[ |
|
|
|
'label' => '<span class="glyphicon glyphicon-cog"></span> Administration', |
|
|
|
'url' => $this->getUrlManagerBackend()->createAbsoluteUrl(['site/index']), |
|
|
|
'visible' => isset(Yii::$app->user->identity) && $this->getUserManager()->isProducer(\Yii::$app->user->identity), |
|
|
|
'options' => ['id' => 'btn-administration'] |
|
|
|
], |
|
|
|
],*/ |
|
|
|
], |
|
|
|
]); |
|
|
|
?> |