diff --git a/frontend/views/layouts/company.php b/frontend/views/layouts/company.php
index c533cec..3a13dde 100755
--- a/frontend/views/layouts/company.php
+++ b/frontend/views/layouts/company.php
@@ -157,39 +157,49 @@
-
params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
- echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
- } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
- echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ if($this->params[ 'company' ]->userInfo->is_freelancer xor $this->params[ 'company' ]->userInfo->is_customer) {
+ if(!empty($this->params[ 'type' ]) && $this->params[ 'type' ] == 'customer') {
+ echo Html::tag('span', 'Заказчик', [ 'class' => 'activejob_span' ]);
+ } else {
+ echo Html::tag('span', 'Исполнитель', [ 'class' => 'activejob_span' ]);
+ }
} else {
- echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ if(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
+ echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
+ } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
+ echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ } else {
+ echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ }
+ ?>
+
+
-
diff --git a/frontend/views/layouts/gallery-company.php b/frontend/views/layouts/gallery-company.php
index fee91a9..f499ee4 100755
--- a/frontend/views/layouts/gallery-company.php
+++ b/frontend/views/layouts/gallery-company.php
@@ -154,39 +154,49 @@
-
params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
- echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
- } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
- echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ if($this->params[ 'company' ]->userInfo->is_freelancer xor $this->params[ 'company' ]->userInfo->is_customer) {
+ if(!empty($this->params[ 'type' ]) && $this->params[ 'type' ] == 'customer') {
+ echo Html::tag('span', 'Заказчик', [ 'class' => 'activejob_span' ]);
+ } else {
+ echo Html::tag('span', 'Исполнитель', [ 'class' => 'activejob_span' ]);
+ }
} else {
- echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ if(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
+ echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
+ } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
+ echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ } else {
+ echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ }
+ ?>
+
+
-
diff --git a/frontend/views/layouts/gallery.php b/frontend/views/layouts/gallery.php
index 3607f4d..a068c1b 100755
--- a/frontend/views/layouts/gallery.php
+++ b/frontend/views/layouts/gallery.php
@@ -68,8 +68,8 @@
],
],
[
- 'label' => 'Портфолио',
- 'url' => [
+ 'label' => 'Портфолио',
+ 'url' => [
'performer/portfolio',
'performer_id' => $this->params[ 'user' ]->id,
'type' => ( !empty( $this->params[ 'type' ] ) ) ? $this->params[ 'type' ] : NULL,
@@ -77,8 +77,8 @@
'visible' => ( empty( $this->params[ 'type' ] ) || $this->params[ 'type' ] == 'implementer' ) ? true : false,
],
[
- 'label' => 'Заказанные работы',
- 'url' => [
+ 'label' => 'Заказанные работы',
+ 'url' => [
'performer/projects',
'performer_id' => $this->params[ 'user' ]->id,
'type' => ( !empty( $this->params[ 'type' ] ) ) ? $this->params[ 'type' ] : NULL,
@@ -134,39 +134,49 @@
-
params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
- echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
- } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
- echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ if($this->params[ 'user' ]->userInfo->is_freelancer xor $this->params[ 'user' ]->userInfo->is_customer) {
+ if(!empty($this->params[ 'type' ]) && $this->params[ 'type' ] == 'customer') {
+ echo Html::tag('span', 'Заказчик', [ 'class' => 'activejob_span' ]);
+ } else {
+ echo Html::tag('span', 'Исполнитель', [ 'class' => 'activejob_span' ]);
+ }
} else {
- echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ if(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'implementer') {
+ echo Html::a('Исполнитель', Url::current([ 'type' => 'implementer' ]));
+ } elseif(!empty( $this->params[ 'type' ] ) && $this->params[ 'type' ] == 'customer') {
+ echo Html::a('Заказчик', Url::current([ 'type' => NULL ]));
+ } else {
+ echo Html::a('Исполнитель', Url::current([ 'type' => NULL ]));
+ }
+ ?>
+
+
-
diff --git a/frontend/views/layouts/performer.php b/frontend/views/layouts/performer.php
index 61e70f2..da4dc99 100755
--- a/frontend/views/layouts/performer.php
+++ b/frontend/views/layouts/performer.php
@@ -140,7 +140,7 @@
params[ 'user' ]->userInfo->is_freelancer xor $this->params[ 'user' ]->userInfo->is_customer) {
- if($this->params[ 'type' ] == 'customer') {
+ if(!empty($this->params[ 'type' ]) && $this->params[ 'type' ] == 'customer') {
echo Html::tag('span', 'Заказчик', [ 'class' => 'activejob_span' ]);
} else {
echo Html::tag('span', 'Исполнитель', [ 'class' => 'activejob_span' ]);
--
libgit2 0.21.4