Commit 239b32497b54befa478b6560f0e3da48fa7a0ad1
1 parent
42648c98
test
Showing
12 changed files
with
309 additions
and
308 deletions
Show diff stats
common/models/User.php
common/widgets/views/phone_field.php
1 | <?php | 1 | <?php |
2 | use yii\helpers\Html; | 2 | use yii\helpers\Html; |
3 | + use yii\validators\RegularExpressionValidator; | ||
3 | use yii\widgets\MaskedInput; | 4 | use yii\widgets\MaskedInput; |
4 | 5 | ||
5 | ?> | 6 | ?> |
@@ -8,24 +9,25 @@ | @@ -8,24 +9,25 @@ | ||
8 | <div class="field_list"> | 9 | <div class="field_list"> |
9 | 10 | ||
10 | 11 | ||
11 | - <?php $t = 0; | 12 | + <?php $t = 0; |
12 | 13 | ||
13 | - $label = 0; // add this var | 14 | + $label = 0; // add this var |
14 | 15 | ||
15 | - for($i=1; $i <= count($model); $i++): | ||
16 | - $row = $i; | ||
17 | - | ||
18 | - ?> | ||
19 | - | ||
20 | - <?= Html::beginTag('div',['class'=>'form-group','id'=>isset($model[$i]['parent_key']) ? $model[$i]['parent_key'] : 0 ])?> | ||
21 | - <div class="input-blocks"> | ||
22 | - <label for="cont-phone-<?= ++$label ?>">Телефон</label> | ||
23 | - <input id="cont-phone-<?= $label ?>" type="tel" pattern="^\+?(?:\d{0,3})?[\(\s]?\d{0,5}[\)\s]?\d{3}[-\s]?\d{2}[-\s]?\d{2}$" placeholder="+xx(xxx)xxx-xx-xx" class="form-control custom-input-2" value="<?= isset($model[$t]['value']) ? $model[$t]['value'] : '' ?>" name="Fields[phone][<?=$row?>][0][phone]" /> | ||
24 | - </div> | ||
25 | - <span data-id="<?= isset($model[$i]['parent_key']) ? $model[$i]['parent_key'] : 0 ?>" title="<?= Yii::t('app','add') ?>" class="glyphicon glyphicon-trash delete-field-item"></span> | ||
26 | - <?= Html::endTag('div')?> | ||
27 | - <?php $i = ++ $t; ?> | ||
28 | - <?php endfor; ?> | 16 | + for($i = 1; $i <= count($model); $i++): |
17 | + $row = $i; | ||
18 | + ?> | ||
19 | + <?= Html::beginTag('div', [ | ||
20 | + 'class' => 'form-group', | ||
21 | + 'id' => isset( $model[ $i ][ 'parent_key' ] ) ? $model[ $i ][ 'parent_key' ] : 0, | ||
22 | + ]) ?> | ||
23 | + <div class="input-blocks"> | ||
24 | + <label for="cont-phone-<?= ++$label ?>">Телефон</label> | ||
25 | + <input id="cont-phone-<?= $label ?>" type="tel" pattern="^\+?(?:\d{0,3})?[\(\s]?\d{0,5}[\)\s]?\d{3}[-\s]?\d{2}[-\s]?\d{2}$" placeholder="+xx(xxx)xxx-xx-xx" class="form-control custom-input-2" value="<?= isset( $model[ $t ][ 'value' ] ) ? $model[ $t ][ 'value' ] : '' ?>" name="Fields[phone][<?= $row ?>][0][phone]"/> | ||
26 | + </div> | ||
27 | + <span data-id="<?= isset( $model[ $i ][ 'parent_key' ] ) ? $model[ $i ][ 'parent_key' ] : 0 ?>" title="<?= Yii::t('app', 'add') ?>" class="glyphicon glyphicon-trash delete-field-item"></span> | ||
28 | + <?= Html::endTag('div') ?> | ||
29 | + <?php $i = ++$t; ?> | ||
30 | + <?php endfor; ?> | ||
29 | 31 | ||
30 | </div> | 32 | </div> |
31 | <p class="btn btn-success add_field_<?= $this->context->id ?>">Добавить еще</p> | 33 | <p class="btn btn-success add_field_<?= $this->context->id ?>">Добавить еще</p> |
@@ -34,23 +36,22 @@ | @@ -34,23 +36,22 @@ | ||
34 | <script> | 36 | <script> |
35 | var start_i_<?=$this->context->id?> = <?=$i?>; | 37 | var start_i_<?=$this->context->id?> = <?=$i?>; |
36 | var start_label_<?=$this->context->id?> = <?=$label?>; // add this var | 38 | var start_label_<?=$this->context->id?> = <?=$label?>; // add this var |
37 | - $( document ).ready(function(){ | ||
38 | - $('.add_field_<?=$this->context->id?>').click(function(){ | ||
39 | - var block = $ (this) | ||
40 | - .siblings('.field_list'); | ||
41 | - var block_id = $(this).parent('fieldset'); | ||
42 | - var sub_block = '<div class="form-group" >'+ | ||
43 | - '<div class="input-blocks">'+ | ||
44 | - '<label for="cont-phone-' + ++start_label_<?=$this->context->id?> +'">Телефон</label>'+ | ||
45 | - '<input id="cont-phone-' + start_label_<?=$this->context->id?> +'" type="tel" pattern="^\\+?(?:\\d{0,3})?[\\(\\s]?\\d{0,5}[\\)\\s]?\\d{3}[-\\s]?\\d{2}[-\\s]?\\d{2}$" placeholder="+xx(xxx)xxx-xx-xx" class="form-control custom-input-2" value="" name="Fields[phone]['+ start_i_<?=$this->context->id?>++ +'][0][phone]" />'+ | ||
46 | - '</div>'+ | ||
47 | - '<span class="glyphicon glyphicon-trash delete-field-item custom-remove-ico"></span>'+ | ||
48 | - '<div>'; | ||
49 | -// console.log(block); | ||
50 | - block.append(sub_block); | ||
51 | - | ||
52 | - }); | ||
53 | - }); | 39 | + $(document).ready( |
40 | + function() | ||
41 | + { | ||
42 | + $('.add_field_<?=$this->context->id?>').click( | ||
43 | + function() | ||
44 | + { | ||
45 | + var block = $(this) | ||
46 | + .siblings('.field_list'); | ||
47 | + var block_id = $(this).parent('fieldset'); | ||
48 | + var sub_block = '<div class="form-group" >' + '<div class="input-blocks">' + '<label for="cont-phone-' + ++start_label_<?=$this->context->id?> + '">Телефон</label>' + '<input id="cont-phone-' + start_label_<?=$this->context->id?> + '" type="tel" pattern="^\\+?(?:\\d{0,3})?[\\(\\s]?\\d{0,5}[\\)\\s]?\\d{3}[-\\s]?\\d{2}[-\\s]?\\d{2}$" placeholder="+xx(xxx)xxx-xx-xx" class="form-control custom-input-2" value="" name="Fields[phone][' + start_i_<?=$this->context->id?>++ + '][0][phone]" />' + '</div>' + '<span class="glyphicon glyphicon-trash delete-field-item custom-remove-ico"></span>' + '<div>'; | ||
49 | + block.append(sub_block); | ||
50 | + | ||
51 | + } | ||
52 | + ); | ||
53 | + } | ||
54 | + ); | ||
54 | </script> | 55 | </script> |
55 | 56 | ||
56 | 57 |
frontend/controllers/AccountsController.php
@@ -1041,7 +1041,7 @@ | @@ -1041,7 +1041,7 @@ | ||
1041 | $user->new_password = $post[ 'new_password' ]; | 1041 | $user->new_password = $post[ 'new_password' ]; |
1042 | } | 1042 | } |
1043 | if(empty( $post[ 'old_password' ] )) { | 1043 | if(empty( $post[ 'old_password' ] )) { |
1044 | - $user->addError('old_password', 'Введите новый пароль'); | 1044 | + $user->addError('old_password', 'Введите старый пароль'); |
1045 | } else { | 1045 | } else { |
1046 | $user->old_password = $post[ 'old_password' ]; | 1046 | $user->old_password = $post[ 'old_password' ]; |
1047 | } | 1047 | } |
frontend/controllers/CompanyController.php
@@ -16,6 +16,7 @@ | @@ -16,6 +16,7 @@ | ||
16 | use yii\data\ArrayDataProvider; | 16 | use yii\data\ArrayDataProvider; |
17 | use yii\data\Pagination; | 17 | use yii\data\Pagination; |
18 | use yii\data\Sort; | 18 | use yii\data\Sort; |
19 | + use yii\db\ActiveQuery; | ||
19 | use yii\helpers\ArrayHelper; | 20 | use yii\helpers\ArrayHelper; |
20 | use yii\web\BadRequestHttpException; | 21 | use yii\web\BadRequestHttpException; |
21 | use yii\web\Controller; | 22 | use yii\web\Controller; |
@@ -178,7 +179,7 @@ | @@ -178,7 +179,7 @@ | ||
178 | 'pagination' => [ | 179 | 'pagination' => [ |
179 | 'pageSize' => 9, | 180 | 'pageSize' => 9, |
180 | ], | 181 | ], |
181 | - 'sort' => new Sort([ | 182 | + 'sort' => new Sort([ |
182 | 'defaultOrder' => [ | 183 | 'defaultOrder' => [ |
183 | 'portfolio_id' => SORT_DESC, | 184 | 'portfolio_id' => SORT_DESC, |
184 | ], | 185 | ], |
@@ -248,15 +249,33 @@ | @@ -248,15 +249,33 @@ | ||
248 | $user = User::findOne($company_id); | 249 | $user = User::findOne($company_id); |
249 | $portfolio = $user->getPortfolios() | 250 | $portfolio = $user->getPortfolios() |
250 | ->where([ 'portfolio_id' => $portfolio_id ]) | 251 | ->where([ 'portfolio_id' => $portfolio_id ]) |
251 | - ->with('portfolioUsers') | 252 | + ->with([ |
253 | + 'portfolioUsers' => function($query) { | ||
254 | + /** | ||
255 | + * @var ActiveQuery $query | ||
256 | + */ | ||
257 | + $query->andWhere([ 'status' => 1 ]); | ||
258 | + }, | ||
259 | + ]) | ||
252 | ->with('portfolioUsers.gallery') | 260 | ->with('portfolioUsers.gallery') |
253 | ->one(); | 261 | ->one(); |
254 | if(!empty( $portfolio_user )) { | 262 | if(!empty( $portfolio_user )) { |
255 | $portfolio_user = PortfolioUser::find() | 263 | $portfolio_user = PortfolioUser::find() |
256 | - ->where([ 'portfolio_user_id' => $portfolio_user ]) | 264 | + ->where([ |
265 | + 'portfolio_user_id' => $portfolio_user, | ||
266 | + 'status' => 1, | ||
267 | + ]) | ||
257 | ->with('gallery') | 268 | ->with('gallery') |
258 | ->with('user') | 269 | ->with('user') |
259 | ->one(); | 270 | ->one(); |
271 | + if(empty( $portfolio_user )) { | ||
272 | + $this->redirect([ | ||
273 | + 'portfolio-view', | ||
274 | + 'performer_id' => $company_id, | ||
275 | + 'portfolio_id' => $portfolio_id, | ||
276 | + 'type' => $type, | ||
277 | + ]); | ||
278 | + } | ||
260 | } else { | 279 | } else { |
261 | $portfolio->updateCounters([ 'view_count' => 1 ]); | 280 | $portfolio->updateCounters([ 'view_count' => 1 ]); |
262 | } | 281 | } |
frontend/controllers/PerformerController.php
@@ -12,6 +12,7 @@ | @@ -12,6 +12,7 @@ | ||
12 | use yii\data\ArrayDataProvider; | 12 | use yii\data\ArrayDataProvider; |
13 | use yii\data\Pagination; | 13 | use yii\data\Pagination; |
14 | use yii\data\Sort; | 14 | use yii\data\Sort; |
15 | + use yii\db\ActiveQuery; | ||
15 | use yii\helpers\ArrayHelper; | 16 | use yii\helpers\ArrayHelper; |
16 | use yii\web\BadRequestHttpException; | 17 | use yii\web\BadRequestHttpException; |
17 | use yii\web\Controller; | 18 | use yii\web\Controller; |
@@ -182,15 +183,33 @@ | @@ -182,15 +183,33 @@ | ||
182 | $user = User::findOne($performer_id); | 183 | $user = User::findOne($performer_id); |
183 | $portfolio = $user->getPortfolios() | 184 | $portfolio = $user->getPortfolios() |
184 | ->where([ 'portfolio_id' => $portfolio_id ]) | 185 | ->where([ 'portfolio_id' => $portfolio_id ]) |
185 | - ->with('portfolioUsers') | 186 | + ->with([ |
187 | + 'portfolioUsers' => function($query) { | ||
188 | + /** | ||
189 | + * @var ActiveQuery $query | ||
190 | + */ | ||
191 | + $query->andWhere([ 'status' => 1 ]); | ||
192 | + }, | ||
193 | + ]) | ||
186 | ->with('portfolioUsers.gallery') | 194 | ->with('portfolioUsers.gallery') |
187 | ->one(); | 195 | ->one(); |
188 | if(!empty( $portfolio_user )) { | 196 | if(!empty( $portfolio_user )) { |
189 | $portfolio_user = PortfolioUser::find() | 197 | $portfolio_user = PortfolioUser::find() |
190 | - ->where([ 'portfolio_user_id' => $portfolio_user ]) | 198 | + ->where([ |
199 | + 'portfolio_user_id' => $portfolio_user, | ||
200 | + 'status' => 1, | ||
201 | + ]) | ||
191 | ->with('gallery') | 202 | ->with('gallery') |
192 | ->with('user') | 203 | ->with('user') |
193 | ->one(); | 204 | ->one(); |
205 | + if(empty( $portfolio_user )) { | ||
206 | + $this->redirect([ | ||
207 | + 'portfolio-view', | ||
208 | + 'performer_id' => $performer_id, | ||
209 | + 'portfolio_id' => $portfolio_id, | ||
210 | + 'type' => $type, | ||
211 | + ]); | ||
212 | + } | ||
194 | } else { | 213 | } else { |
195 | $portfolio->updateCounters([ 'view_count' => 1 ]); | 214 | $portfolio->updateCounters([ 'view_count' => 1 ]); |
196 | } | 215 | } |
frontend/messages/ru/app.php
@@ -179,5 +179,4 @@ | @@ -179,5 +179,4 @@ | ||
179 | 'Feedback answer' => 'Вопрос', | 179 | 'Feedback answer' => 'Вопрос', |
180 | 'Feedback file' => 'Файл', | 180 | 'Feedback file' => 'Файл', |
181 | 'Feedback date add' => 'Дата обращения', | 181 | 'Feedback date add' => 'Дата обращения', |
182 | - 'Projects' => 'Проекты', | ||
183 | ]; | 182 | ]; |
184 | \ No newline at end of file | 183 | \ No newline at end of file |
frontend/views/accounts/_portfolio_form.php
@@ -288,9 +288,9 @@ $form->end(); | @@ -288,9 +288,9 @@ $form->end(); | ||
288 | $.post( | 288 | $.post( |
289 | "/accounts/gallery-cover", {gallery_id : gallery_id}, function(data) | 289 | "/accounts/gallery-cover", {gallery_id : gallery_id}, function(data) |
290 | { | 290 | { |
291 | - if(!($('#cover_old_img').val().length)) | 291 | + if(!($('#cover_old_img').val().length) && !($('#portfolio-cover').val().length)) |
292 | { | 292 | { |
293 | - $('#cover_picture_link').val(data); | 293 | + $('#portfolio-cover').val(data); |
294 | var newimg = document.createElement("img"); | 294 | var newimg = document.createElement("img"); |
295 | newimg.setAttribute("src", data); | 295 | newimg.setAttribute("src", data); |
296 | 296 |
frontend/views/accounts/projects.php
@@ -66,7 +66,7 @@ | @@ -66,7 +66,7 @@ | ||
66 | [ | 66 | [ |
67 | 'attribute' => 'budget', | 67 | 'attribute' => 'budget', |
68 | 'filter' => Html::activeInput('text', $searchModel, 'budget_approx', ['class'=>'form-control']), | 68 | 'filter' => Html::activeInput('text', $searchModel, 'budget_approx', ['class'=>'form-control']), |
69 | - 'value' => function($model, $key, $index, $column) { | 69 | + 'content' => function($model, $key, $index, $column) { |
70 | /** | 70 | /** |
71 | * @var Project $model | 71 | * @var Project $model |
72 | */ | 72 | */ |
frontend/views/layouts/admin.php
@@ -59,7 +59,7 @@ | @@ -59,7 +59,7 @@ | ||
59 | 'active' => preg_match('/^blog.*$/', $this->context->action->id) ? true : false, | 59 | 'active' => preg_match('/^blog.*$/', $this->context->action->id) ? true : false, |
60 | ], | 60 | ], |
61 | [ | 61 | [ |
62 | - 'label' => 'Галерея Изображения', | 62 | + 'label' => 'Галерея Изображений', |
63 | 'url' => [ 'accounts/gallery' ], | 63 | 'url' => [ 'accounts/gallery' ], |
64 | 'active' => preg_match('/^gallery(?!-video).*$/', $this->context->action->id) ? true : false, | 64 | 'active' => preg_match('/^gallery(?!-video).*$/', $this->context->action->id) ? true : false, |
65 | ], | 65 | ], |
frontend/views/layouts/main.php
1 | <?php | 1 | <?php |
2 | 2 | ||
3 | -/* @var $this \yii\web\View */ | ||
4 | -/* @var $content string */ | 3 | + /* @var $this \yii\web\View */ |
4 | + /* @var $content string */ | ||
5 | 5 | ||
6 | -use yii\helpers\Html; | ||
7 | -use yii\widgets\Menu; | ||
8 | -use frontend\assets\AppAsset; | ||
9 | -AppAsset::register($this); | 6 | + use yii\helpers\Html; |
7 | + use yii\widgets\Menu; | ||
8 | + use frontend\assets\AppAsset; | ||
9 | + | ||
10 | + AppAsset::register($this); | ||
10 | ?> | 11 | ?> |
11 | 12 | ||
12 | <?php $this->beginPage() ?> | 13 | <?php $this->beginPage() ?> |
@@ -18,8 +19,6 @@ AppAsset::register($this); | @@ -18,8 +19,6 @@ AppAsset::register($this); | ||
18 | <head> | 19 | <head> |
19 | 20 | ||
20 | 21 | ||
21 | - | ||
22 | - | ||
23 | <meta charset="<?= Yii::$app->charset ?>"> | 22 | <meta charset="<?= Yii::$app->charset ?>"> |
24 | 23 | ||
25 | <?= Html::csrfMetaTags() ?> | 24 | <?= Html::csrfMetaTags() ?> |
@@ -39,32 +38,36 @@ AppAsset::register($this); | @@ -39,32 +38,36 @@ AppAsset::register($this); | ||
39 | <a href="/"><img class="logo" src="/images/logo.png" width="100" height="68" alt=""/></a> | 38 | <a href="/"><img class="logo" src="/images/logo.png" width="100" height="68" alt=""/></a> |
40 | <div class="header-proektant-slogan">Международная Федерация Проектантов</div> | 39 | <div class="header-proektant-slogan">Международная Федерация Проектантов</div> |
41 | <ul class="header-contacts-menu"> | 40 | <ul class="header-contacts-menu"> |
42 | - <li><span><img src="/images/icon_question_01.png" alt=""/></span><?= Html::a('Задать вопрос','', ['class' =>'contactsLinkModalFirst'])?></li> | ||
43 | - <li><span><img src="/images/icon_help_01.png" alt=""/></span><?= Html::a('Помощь',['/site/help'], ['class' =>'contactsLinkModal'])?></li> | 41 | + <li> |
42 | + <span><img src="/images/icon_question_01.png" alt=""/></span><?= Html::a('Задать вопрос', '', [ 'class' => 'contactsLinkModalFirst' ]) ?> | ||
43 | + </li> | ||
44 | + <li> | ||
45 | + <span><img src="/images/icon_help_01.png" alt=""/></span><?= Html::a('Помощь', [ '/site/help' ], [ 'class' => 'contactsLinkModal' ]) ?> | ||
46 | + </li> | ||
44 | </ul> | 47 | </ul> |
45 | <div class="header-cabinet-wr"> | 48 | <div class="header-cabinet-wr"> |
46 | <?php | 49 | <?php |
47 | - if (Yii::$app->user->isGuest): ?> | ||
48 | - <div class="header-cabinet-foto"> | 50 | + if(Yii::$app->user->isGuest): ?> |
51 | + <div class="header-cabinet-foto"> | ||
49 | 52 | ||
50 | - </div> | ||
51 | - <div class="header-cabinet-profile not-login">Профиль</div> | ||
52 | - <div> | ||
53 | - <?= Html::a('Вход',['/site/login'], ['class'=>'loginLinkModal']) ?> | ||
54 | - <?= Html::a('Регистрация',['/site/registration']) ?> | ||
55 | - </div> | 53 | + </div> |
54 | + <div class="header-cabinet-profile not-login">Профиль</div> | ||
55 | + <div> | ||
56 | + <?= Html::a('Вход', [ '/site/login' ], [ 'class' => 'loginLinkModal' ]) ?> | ||
57 | + <?= Html::a('Регистрация', [ '/site/registration' ]) ?> | ||
58 | + </div> | ||
56 | 59 | ||
57 | - <?php else : ?> | ||
58 | - <div class="header-cabinet-foto"> | ||
59 | - <?php | ||
60 | - if(!empty(\Yii::$app->user->identity->userInfo->image)) { | ||
61 | - echo Html::img(Yii::$app->user->identity->minImg(Yii::$app->user->identity->userInfo->image,48,48)); | ||
62 | - } | ||
63 | - ?> | ||
64 | - </div> | ||
65 | - <div class="header-cabinet-profile">Профиль</div> | ||
66 | - <?= Html::a(Yii::$app->user->identity->email,['/accounts']) ?> | ||
67 | - <?php endif; ?> | 60 | + <?php else : ?> |
61 | + <div class="header-cabinet-foto"> | ||
62 | + <?php | ||
63 | + if(!empty( \Yii::$app->user->identity->userInfo->image )) { | ||
64 | + echo Html::img(Yii::$app->user->identity->minImg(Yii::$app->user->identity->userInfo->image, 48, 48)); | ||
65 | + } | ||
66 | + ?> | ||
67 | + </div> | ||
68 | + <div class="header-cabinet-profile">Профиль</div> | ||
69 | + <?= Html::a(Yii::$app->user->identity->email, [ '/accounts' ]) ?> | ||
70 | + <?php endif; ?> | ||
68 | 71 | ||
69 | </div> | 72 | </div> |
70 | </div> | 73 | </div> |
@@ -82,18 +85,18 @@ AppAsset::register($this); | @@ -82,18 +85,18 @@ AppAsset::register($this); | ||
82 | 85 | ||
83 | <li> | 86 | <li> |
84 | <?php | 87 | <?php |
85 | - if(\Yii::$app->user->isGuest) { | ||
86 | - echo Html::a('Войти в профиль', ['site/login']); | ||
87 | - } else { | ||
88 | - echo Html::a('Редактировать профиль', ['accounts/']); | ||
89 | - } | 88 | + if(\Yii::$app->user->isGuest) { |
89 | + echo Html::a('Войти в профиль', [ 'site/login' ]); | ||
90 | + } else { | ||
91 | + echo Html::a('Редактировать профиль', [ 'accounts/' ]); | ||
92 | + } | ||
90 | ?> | 93 | ?> |
91 | </li> | 94 | </li> |
92 | </ul> | 95 | </ul> |
93 | <ul> | 96 | <ul> |
94 | - <li><?= Html::a(Yii::t('app', 'Project list'), ['search/project'])?></li> | ||
95 | - <li><?= Html::a('Список вакансий', ['search/vacancy'])?></li> | ||
96 | - <li><?= Html::a('Список заказчиков', ['search/customer'])?></li> | 97 | + <li><?= Html::a(Yii::t('app', 'Project list'), [ 'search/project' ]) ?></li> |
98 | + <li><?= Html::a('Список вакансий', [ 'search/vacancy' ]) ?></li> | ||
99 | + <li><?= Html::a('Список заказчиков', [ 'search/customer' ]) ?></li> | ||
97 | </ul> | 100 | </ul> |
98 | </div> | 101 | </div> |
99 | </li> | 102 | </li> |
@@ -102,13 +105,19 @@ AppAsset::register($this); | @@ -102,13 +105,19 @@ AppAsset::register($this); | ||
102 | <div class="main-menu-hover"> | 105 | <div class="main-menu-hover"> |
103 | <ul> | 106 | <ul> |
104 | 107 | ||
105 | - <li><?= Html::a(Yii::t('app', 'Add project'), ['accounts/projects-create'])?></li> | ||
106 | - <li><?= Html::a('Разместить вакансию', ['accounts/vacancy'])?></li> | 108 | + <li><?= Html::a(Yii::t('app', 'Add project'), [ 'accounts/projects-create' ]) ?></li> |
109 | + <li><?= Html::a('Разместить вакансию', [ 'accounts/vacancy' ]) ?></li> | ||
107 | </ul> | 110 | </ul> |
108 | <ul> | 111 | <ul> |
109 | 112 | ||
110 | - <li><?= Html::a('Список проектантов', ['search/performer','SearchPerformerForm[type]'=>'1'])?></li> | ||
111 | - <li><?= Html::a('Список проектных компаний', ['search/performer','SearchPerformerForm[type]'=>'2'])?></li> | 113 | + <li><?= Html::a('Список проектантов', [ |
114 | + 'search/performer', | ||
115 | + 'SearchPerformerForm[type]' => '1', | ||
116 | + ]) ?></li> | ||
117 | + <li><?= Html::a('Список проектных компаний', [ | ||
118 | + 'search/performer', | ||
119 | + 'SearchPerformerForm[type]' => '2', | ||
120 | + ]) ?></li> | ||
112 | </ul> | 121 | </ul> |
113 | </div> | 122 | </div> |
114 | </li> | 123 | </li> |
@@ -117,14 +126,14 @@ AppAsset::register($this); | @@ -117,14 +126,14 @@ AppAsset::register($this); | ||
117 | <div class="main-menu-hover"> | 126 | <div class="main-menu-hover"> |
118 | <ul> | 127 | <ul> |
119 | 128 | ||
120 | - <li><?= Html::a(Yii::t('app', 'Add project'), ['accounts/projects-create'])?></li> | ||
121 | - <li><?= Html::a('Разместить вакансию', ['accounts/vacancy-create'])?></li> | ||
122 | - <li><?= Html::a('Редактировать портфолио', ['accounts/portfolio'])?></li> | 129 | + <li><?= Html::a(Yii::t('app', 'Add project'), [ 'accounts/projects-create' ]) ?></li> |
130 | + <li><?= Html::a('Разместить вакансию', [ 'accounts/vacancy-create' ]) ?></li> | ||
131 | + <li><?= Html::a('Редактировать портфолио', [ 'accounts/portfolio' ]) ?></li> | ||
123 | </ul> | 132 | </ul> |
124 | <ul> | 133 | <ul> |
125 | - <li><?= Html::a('Список проектантов', ['search/performer'])?></li> | ||
126 | - <li><?= Html::a(Yii::t('app', 'Project list'), ['search/project'])?></li> | ||
127 | - <li><?= Html::a('Список заказчиков', ['search/customer'])?></li> | 134 | + <li><?= Html::a('Список проектантов', [ 'search/performer' ]) ?></li> |
135 | + <li><?= Html::a(Yii::t('app', 'Project list'), [ 'search/project' ]) ?></li> | ||
136 | + <li><?= Html::a('Список заказчиков', [ 'search/customer' ]) ?></li> | ||
128 | </ul> | 137 | </ul> |
129 | </div> | 138 | </div> |
130 | </li> | 139 | </li> |
@@ -133,12 +142,12 @@ AppAsset::register($this); | @@ -133,12 +142,12 @@ AppAsset::register($this); | ||
133 | <div class="search-main-menu"> | 142 | <div class="search-main-menu"> |
134 | <form action=""> | 143 | <form action=""> |
135 | <input value="" name="" type="search"/> | 144 | <input value="" name="" type="search"/> |
136 | - <input type="hidden" value="1" name="" /> | 145 | + <input type="hidden" value="1" name=""/> |
137 | <button type="submit" value=""></button> | 146 | <button type="submit" value=""></button> |
138 | <div class="search-list"> | 147 | <div class="search-list"> |
139 | - <span><?=Yii::t('app', 'Projects')?></span> | 148 | + <span><?= Yii::t('app', 'Projects') ?></span> |
140 | <ul class="search-ul"> | 149 | <ul class="search-ul"> |
141 | - <li><?=Yii::t('app', 'Projects')?></li> | 150 | + <li><?= Yii::t('app', 'Projects') ?></li> |
142 | <li>Исполнители</li> | 151 | <li>Исполнители</li> |
143 | <li>Заказчики</li> | 152 | <li>Заказчики</li> |
144 | </ul> | 153 | </ul> |
@@ -148,25 +157,25 @@ AppAsset::register($this); | @@ -148,25 +157,25 @@ AppAsset::register($this); | ||
148 | <?php | 157 | <?php |
149 | if(!\Yii::$app->user->isGuest) { | 158 | if(!\Yii::$app->user->isGuest) { |
150 | echo Menu::widget([ | 159 | echo Menu::widget([ |
151 | - 'options' => [ | ||
152 | - 'tag' => 'div', | 160 | + 'options' => [ |
161 | + 'tag' => 'div', | ||
153 | 'class' => 'main-menu-icons-wr', | 162 | 'class' => 'main-menu-icons-wr', |
154 | ], | 163 | ], |
155 | 'itemOptions' => [ | 164 | 'itemOptions' => [ |
156 | 'tag' => false, | 165 | 'tag' => false, |
157 | ], | 166 | ], |
158 | - 'items' => [ | 167 | + 'items' => [ |
159 | [ | 168 | [ |
160 | - 'url' => ['/projects'], | ||
161 | - 'template' => '<a href="{url}" class="main-menu-icons-home"><span>'.count(\Yii::$app->user->identity->commentProjects).'</span></a>', | 169 | + 'url' => [ '/projects' ], |
170 | + 'template' => '<a href="{url}" class="main-menu-icons-home"><span>' . count(\Yii::$app->user->identity->commentProjects) . '</span></a>', | ||
162 | ], | 171 | ], |
163 | [ | 172 | [ |
164 | - 'url' => ['chat/list'], | ||
165 | - 'template' => '<a href="{url}" class="main-menu-icons-edit"><span>'.\Yii::$app->user->identity->chatCount.'</span></a>', | 173 | + 'url' => [ 'chat/list' ], |
174 | + 'template' => '<a href="{url}" class="main-menu-icons-edit"><span>' . \Yii::$app->user->identity->chatCount . '</span></a>', | ||
166 | ], | 175 | ], |
167 | [ | 176 | [ |
168 | - 'url' => ['/bookmarks'], | ||
169 | - 'template' => "<a href='{url}' class='main-menu-icons-copy'><span>".count(\Yii::$app->user->identity->bookmarks)."</span></a>", | 177 | + 'url' => [ '/bookmarks' ], |
178 | + 'template' => "<a href='{url}' class='main-menu-icons-copy'><span>" . count(\Yii::$app->user->identity->bookmarks) . "</span></a>", | ||
170 | ], | 179 | ], |
171 | ], | 180 | ], |
172 | ]); | 181 | ]); |
@@ -189,70 +198,78 @@ AppAsset::register($this); | @@ -189,70 +198,78 @@ AppAsset::register($this); | ||
189 | <div class="footer-all-wr"> | 198 | <div class="footer-all-wr"> |
190 | <div class="footer-menu-wrapper first-footer-menu"> | 199 | <div class="footer-menu-wrapper first-footer-menu"> |
191 | <?php | 200 | <?php |
201 | + $items = [ | ||
202 | + [ | ||
203 | + 'label' => Yii::t('app', 'Projects'), | ||
204 | + 'url' => [ 'search/project' ], | ||
205 | + ], | ||
206 | + [ | ||
207 | + 'label' => 'Вакансии', | ||
208 | + 'url' => [ 'search/vacancy' ], | ||
209 | + ], | ||
210 | + [ | ||
211 | + 'label' => 'Рейтинг проектантов', | ||
212 | + 'url' => [ 'search/performer' ], | ||
213 | + ], | ||
214 | + ]; | ||
215 | + if(empty( \Yii::$app->user->id )) { | ||
216 | + array_unshift($items, [ | ||
217 | + 'label' => 'Регистрация проектанта', | ||
218 | + 'url' => [ '/site/registration' ], | ||
219 | + ]); | ||
220 | + } | ||
192 | echo Menu::widget([ | 221 | echo Menu::widget([ |
193 | 'options' => [ | 222 | 'options' => [ |
194 | 'class' => 'footer-menu', | 223 | 'class' => 'footer-menu', |
195 | ], | 224 | ], |
196 | - 'items' => [ | ||
197 | - [ | ||
198 | - 'label' => 'Регистрация проектанта', | ||
199 | - 'url' => ['site/signup'], | ||
200 | - ], | ||
201 | - [ | ||
202 | - 'label' => Yii::t('app', 'Projects'), | ||
203 | - 'url' => ['search/project'], | ||
204 | - ], | ||
205 | - [ | ||
206 | - 'label' => 'Вакансии', | ||
207 | - 'url' => ['search/vacancy'], | ||
208 | - ], | ||
209 | - [ | ||
210 | - 'label' => 'Рейтинг проектантов', | ||
211 | - 'url' => ['search/performer'], | ||
212 | - ], | ||
213 | - ] | 225 | + 'items' => $items |
214 | ]); | 226 | ]); |
227 | + unset($items); | ||
215 | ?> | 228 | ?> |
216 | </div> | 229 | </div> |
217 | 230 | ||
218 | <div class="footer-menu-wrapper second-footer-menu"> | 231 | <div class="footer-menu-wrapper second-footer-menu"> |
219 | <?php | 232 | <?php |
233 | + $items = [ | ||
234 | + [ | ||
235 | + 'label' => 'Рейтинг компаний', | ||
236 | + 'url' => [ 'search/performer', 'SearchPerformerForm[type]' => 2 ], | ||
237 | + ] | ||
238 | + ]; | ||
239 | + if(empty( \Yii::$app->user->id )) { | ||
240 | + array_unshift($items, [ | ||
241 | + 'label' => 'Регистрация заказчика', | ||
242 | + 'url' => [ '/site/registration' ], | ||
243 | + ]); | ||
244 | + } | ||
220 | echo Menu::widget([ | 245 | echo Menu::widget([ |
221 | 'options' => [ | 246 | 'options' => [ |
222 | 'class' => 'footer-menu', | 247 | 'class' => 'footer-menu', |
223 | ], | 248 | ], |
224 | - 'items' => [ | ||
225 | - [ | ||
226 | - 'label' => 'Регистрация заказчика', | ||
227 | - 'url' => ['site/signup'], | ||
228 | - ], | ||
229 | - [ | ||
230 | - 'label' => 'Рейтинг компаний', | ||
231 | - 'url' => ['search/index'], | ||
232 | - ], | ||
233 | - ] | 249 | + 'items' => $items, |
234 | ]); | 250 | ]); |
251 | + unset($items); | ||
235 | ?> | 252 | ?> |
236 | <div class="footer-menu-project"> | 253 | <div class="footer-menu-project"> |
237 | <?php | 254 | <?php |
238 | echo Menu::widget([ | 255 | echo Menu::widget([ |
239 | - 'options' => [ | ||
240 | - 'tag' => 'div', | 256 | + 'options' => [ |
257 | + 'tag' => 'div', | ||
241 | 'class' => 'footer-menu-project-ico', | 258 | 'class' => 'footer-menu-project-ico', |
242 | ], | 259 | ], |
243 | 'encodeLabels' => false, | 260 | 'encodeLabels' => false, |
244 | - 'itemOptions' => [ | 261 | + 'itemOptions' => [ |
245 | 'tag' => false, | 262 | 'tag' => false, |
246 | ], | 263 | ], |
247 | 'linkTemplate' => '<a target="_blank" href="{url}">{label}</a>', | 264 | 'linkTemplate' => '<a target="_blank" href="{url}">{label}</a>', |
248 | - 'items' => [ | 265 | + 'items' => [ |
249 | [ | 266 | [ |
250 | 'label' => "<img src='/images/soc-ico-1.png' alt=''/>", | 267 | 'label' => "<img src='/images/soc-ico-1.png' alt=''/>", |
251 | - 'url' => 'http://rss.com', | 268 | + 'url' => 'http://rss.com', |
252 | ], | 269 | ], |
253 | [ | 270 | [ |
254 | 'label' => "<img src='/images/soc-ico-2.png' alt=''/>", | 271 | 'label' => "<img src='/images/soc-ico-2.png' alt=''/>", |
255 | - 'url' => 'http://twitter.com', | 272 | + 'url' => 'http://twitter.com', |
256 | ], | 273 | ], |
257 | ], | 274 | ], |
258 | ]); | 275 | ]); |
@@ -263,49 +280,53 @@ AppAsset::register($this); | @@ -263,49 +280,53 @@ AppAsset::register($this); | ||
263 | 280 | ||
264 | <div class="footer-menu-wrapper third-footer-menu"> | 281 | <div class="footer-menu-wrapper third-footer-menu"> |
265 | <?php | 282 | <?php |
266 | - echo Menu::widget([ | ||
267 | - 'options' => [ | ||
268 | - 'class' => 'footer-menu', | ||
269 | - ], | ||
270 | - 'items' => [ | ||
271 | - [ | ||
272 | - 'label' => 'Регистрация компаний', | ||
273 | - 'url' => ['site/signup'], | ||
274 | - ], | 283 | + $items = [ |
275 | [ | 284 | [ |
276 | 'label' => 'Рейтинг компаний', | 285 | 'label' => 'Рейтинг компаний', |
277 | - 'url' => ['search/company'], | 286 | + 'url' => [ 'search/performer', 'SearchPerformerForm[type]' => 2 ], |
278 | ], | 287 | ], |
279 | - ] | ||
280 | - ]); | ||
281 | - ?> | ||
282 | - <div class="footer-menu-project-two"> | ||
283 | - <?php | 288 | + ]; |
289 | + if(empty( \Yii::$app->user->id )) { | ||
290 | + array_unshift($items, [ | ||
291 | + 'label' => 'Регистрация компаний', | ||
292 | + 'url' => [ '/site/registration' ], | ||
293 | + ]); | ||
294 | + } | ||
284 | echo Menu::widget([ | 295 | echo Menu::widget([ |
285 | 'options' => [ | 296 | 'options' => [ |
286 | - 'tag' => 'div', | ||
287 | - 'class' => 'footer-menu-project-ico', | ||
288 | - ], | ||
289 | - 'encodeLabels' => false, | ||
290 | - 'itemOptions' => [ | ||
291 | - 'tag' => false, | 297 | + 'class' => 'footer-menu', |
292 | ], | 298 | ], |
293 | - 'linkTemplate' => '<a target="_blank" href="{url}">{label}</a>', | ||
294 | - 'items' => [ | ||
295 | - [ | ||
296 | - 'label' => "<img src='/images/soc-ico-3.png' alt=''/>", | ||
297 | - 'url' => 'http://fb.com', | 299 | + 'items' => $items |
300 | + ]); | ||
301 | + unset($items); | ||
302 | + ?> | ||
303 | + <div class="footer-menu-project-two"> | ||
304 | + <?php | ||
305 | + echo Menu::widget([ | ||
306 | + 'options' => [ | ||
307 | + 'tag' => 'div', | ||
308 | + 'class' => 'footer-menu-project-ico', | ||
298 | ], | 309 | ], |
299 | - [ | ||
300 | - 'label' => "<img src='/images/soc-ico-4.png' alt=''/>", | ||
301 | - 'url' => 'http://vk.com', | 310 | + 'encodeLabels' => false, |
311 | + 'itemOptions' => [ | ||
312 | + 'tag' => false, | ||
302 | ], | 313 | ], |
303 | - [ | ||
304 | - 'label' => "<img src='/images/soc-ico-5.png' alt=''/>", | ||
305 | - 'url' => 'http://plus.google.com', | 314 | + 'linkTemplate' => '<a target="_blank" href="{url}">{label}</a>', |
315 | + 'items' => [ | ||
316 | + [ | ||
317 | + 'label' => "<img src='/images/soc-ico-3.png' alt=''/>", | ||
318 | + 'url' => 'http://fb.com', | ||
319 | + ], | ||
320 | + [ | ||
321 | + 'label' => "<img src='/images/soc-ico-4.png' alt=''/>", | ||
322 | + 'url' => 'http://vk.com', | ||
323 | + ], | ||
324 | + [ | ||
325 | + 'label' => "<img src='/images/soc-ico-5.png' alt=''/>", | ||
326 | + 'url' => 'http://plus.google.com', | ||
327 | + ], | ||
306 | ], | 328 | ], |
307 | - ], | ||
308 | - ]); | 329 | + ]); |
309 | ?> | 330 | ?> |
310 | <div class="footer-menu-project-ico-txt">новости сервера</div> | 331 | <div class="footer-menu-project-ico-txt">новости сервера</div> |
311 | </div> | 332 | </div> |
@@ -313,41 +334,41 @@ AppAsset::register($this); | @@ -313,41 +334,41 @@ AppAsset::register($this); | ||
313 | 334 | ||
314 | <div class="footer-menu-wrapper last-footer-menu"> | 335 | <div class="footer-menu-wrapper last-footer-menu"> |
315 | <?php | 336 | <?php |
316 | - echo Menu::widget([ | ||
317 | - 'options' => [ | ||
318 | - 'class' => 'footer-menu', | ||
319 | - ], | ||
320 | - 'items' => [ | ||
321 | - [ | ||
322 | - 'label' => 'Русский', | ||
323 | - 'url' => [' '] | ||
324 | - ], | ||
325 | - [ | ||
326 | - 'label' => 'Конфиденциальность', | ||
327 | - 'url' => [' '] | ||
328 | - ], | ||
329 | - [ | ||
330 | - 'label' => 'Условия использования', | ||
331 | - 'url' => [' '] | ||
332 | - ], | ||
333 | - [ | ||
334 | - 'label' => 'Файлы cookie', | ||
335 | - 'url' => [' '] | ||
336 | - ], | ||
337 | - [ | ||
338 | - 'label' => 'Реклама', | ||
339 | - 'url' => [' '] | ||
340 | - ], | ||
341 | - [ | ||
342 | - 'label' => 'Ad Choices', | ||
343 | - 'url' => [' '] | 337 | + echo Menu::widget([ |
338 | + 'options' => [ | ||
339 | + 'class' => 'footer-menu', | ||
344 | ], | 340 | ], |
345 | - [ | ||
346 | - 'label' => 'Еще', | ||
347 | - 'url' => [' '] | 341 | + 'items' => [ |
342 | + [ | ||
343 | + 'label' => 'Русский', | ||
344 | + 'url' => [ ' ' ], | ||
345 | + ], | ||
346 | + [ | ||
347 | + 'label' => 'Конфиденциальность', | ||
348 | + 'url' => [ ' ' ], | ||
349 | + ], | ||
350 | + [ | ||
351 | + 'label' => 'Условия использования', | ||
352 | + 'url' => [ ' ' ], | ||
353 | + ], | ||
354 | + [ | ||
355 | + 'label' => 'Файлы cookie', | ||
356 | + 'url' => [ ' ' ], | ||
357 | + ], | ||
358 | + [ | ||
359 | + 'label' => 'Реклама', | ||
360 | + 'url' => [ ' ' ], | ||
361 | + ], | ||
362 | + [ | ||
363 | + 'label' => 'Ad Choices', | ||
364 | + 'url' => [ ' ' ], | ||
365 | + ], | ||
366 | + [ | ||
367 | + 'label' => 'Еще', | ||
368 | + 'url' => [ ' ' ], | ||
369 | + ], | ||
348 | ], | 370 | ], |
349 | - ] | ||
350 | - ]); | 371 | + ]); |
351 | ?> | 372 | ?> |
352 | </div> | 373 | </div> |
353 | 374 | ||
@@ -365,7 +386,7 @@ AppAsset::register($this); | @@ -365,7 +386,7 @@ AppAsset::register($this); | ||
365 | <div class="artweb-wr"> | 386 | <div class="artweb-wr"> |
366 | <a target="_blank" href="http://artweb.ua/">Создание сайтов</a> | 387 | <a target="_blank" href="http://artweb.ua/">Создание сайтов</a> |
367 | <div class="artweb-img"> | 388 | <div class="artweb-img"> |
368 | - <a target="_blank" href="http://artweb.ua/"><img src="/images/artweb.png" /></a> | 389 | + <a target="_blank" href="http://artweb.ua/"><img src="/images/artweb.png"/></a> |
369 | </div> | 390 | </div> |
370 | </div> | 391 | </div> |
371 | </div> | 392 | </div> |
frontend/views/performer/portfolio-view.php
@@ -171,8 +171,10 @@ | @@ -171,8 +171,10 @@ | ||
171 | <div class="new-portf-slider-wr style"> | 171 | <div class="new-portf-slider-wr style"> |
172 | <p>Участники проекта:</p> | 172 | <p>Участники проекта:</p> |
173 | <?php | 173 | <?php |
174 | - foreach($portfolio->portfolioUsers as $portfolioUser) { | ||
175 | - $gallery = $portfolio->ShowGallery($portfolioUser->gallery->photo); | 174 | + foreach($portfolio->getPortfolioUsers()->where(['status' => 1])->with('gallery')->all() as $portfolioUser) { |
175 | + if(!empty($portfolioUser->gallery)) { | ||
176 | + $gallery = $portfolio->ShowGallery($portfolioUser->gallery->photo); | ||
177 | + } | ||
176 | ?> | 178 | ?> |
177 | <a href="<?= Url::to([ | 179 | <a href="<?= Url::to([ |
178 | 'performer/portfolio-view', | 180 | 'performer/portfolio-view', |
frontend/views/search/project.php
@@ -74,7 +74,7 @@ | @@ -74,7 +74,7 @@ | ||
74 | 'template' => "{input}\n{label}\n{hint}\n{error}", | 74 | 'template' => "{input}\n{label}\n{hint}\n{error}", |
75 | 'options' => [ 'class' => 'blocks-check-list' ], | 75 | 'options' => [ 'class' => 'blocks-check-list' ], |
76 | ]) | 76 | ]) |
77 | - ->label("<span></span>{$model->getAttributeLabel('contractual')}", ['class' => '']) | 77 | + ->label("<span></span>{$model->getAttributeLabel('contractual')}", [ 'class' => '' ]) |
78 | ->checkbox([ ], false) ?> | 78 | ->checkbox([ ], false) ?> |
79 | <?= $form->field($model, 'payment', [ 'template' => "{input}\n{error}" ]) | 79 | <?= $form->field($model, 'payment', [ 'template' => "{input}\n{error}" ]) |
80 | ->checkboxList($payments, [ | 80 | ->checkboxList($payments, [ |
@@ -94,93 +94,7 @@ | @@ -94,93 +94,7 @@ | ||
94 | </div> | 94 | </div> |
95 | <?php | 95 | <?php |
96 | $form->end(); | 96 | $form->end(); |
97 | - /* | ||
98 | ?> | 97 | ?> |
99 | - <form action="" class="search-work-form"> | ||
100 | - | ||
101 | - <div class="blocks-check-list-wrapp"> | ||
102 | - <div class="blocks-check-title">Профиль</div> | ||
103 | - <div class="blocks-check-list-wrapp"> | ||
104 | - <select> | ||
105 | - <option selected disabled>Дизайн</option> | ||
106 | - <option value="">Ландшафтный дизайн</option> | ||
107 | - <option value="">Интерьерный дизайн</option> | ||
108 | - </select> | ||
109 | - </div> | ||
110 | - | ||
111 | - <div class="blocks-check-list-wrapp"> | ||
112 | - <select> | ||
113 | - <option selected disabled>Архитектура</option> | ||
114 | - <option value="">Ландшафтный дизайн</option> | ||
115 | - <option value="">Интерьерный дизайн</option> | ||
116 | - </select> | ||
117 | - </div> | ||
118 | - | ||
119 | - <div class="blocks-check-list-wrapp"> | ||
120 | - <select> | ||
121 | - <option selected disabled>Строительство</option> | ||
122 | - <option value="">Ландшафтный дизайн</option> | ||
123 | - <option value="">Интерьерный дизайн</option> | ||
124 | - </select> | ||
125 | - </div> | ||
126 | - </div> | ||
127 | - | ||
128 | - <div class="blocks-check-list-wrapp"> | ||
129 | - <div class="blocks-check-title">Регион</div> | ||
130 | - <select> | ||
131 | - <option selected value="">Все страны</option> | ||
132 | - <option style="color: #000; font-weight: bold !important;" value="">Украина</option> | ||
133 | - <option value="">Россия</option> | ||
134 | - <option value="">Белорусь</option> | ||
135 | - </select> | ||
136 | - </div> | ||
137 | - <div class="blocks-check-list-wrapp"> | ||
138 | - <select id="theme-1"> | ||
139 | - <option selected disabled>Город</option> | ||
140 | - <option value="">Все</option> | ||
141 | - <option value="">Киев</option> | ||
142 | - <option value="">Житомир</option> | ||
143 | - <option value="">Львов</option> | ||
144 | - <option value="">Киев</option> | ||
145 | - <option value="">Житомир</option> | ||
146 | - <option value="">Львов</option> | ||
147 | - </select> | ||
148 | - </div> | ||
149 | - | ||
150 | - <div class="blocks-check-list-wrapp"> | ||
151 | - <div class="blocks-check-title">Бюджет</div> | ||
152 | - <div class="form-price-wr"> | ||
153 | - <input type="text" placeholder="от"/> | ||
154 | - <input type="text" placeholder="до"/> | ||
155 | - <div class="blocks-check-list-wrapp check-valuta"> | ||
156 | - <select> | ||
157 | - <option selected>грн</option> | ||
158 | - <option value="">$</option> | ||
159 | - <option value="">eur</option> | ||
160 | - </select> | ||
161 | - </div> | ||
162 | - </div> | ||
163 | - <div class="blocks-check-list"> | ||
164 | - <input type="checkbox" name="group2" class="check-search" id="theme-4"><label for="theme-4"><span></span>Договорной</label> | ||
165 | - </div> | ||
166 | - <div class="blocks-check-list"> | ||
167 | - <input type="checkbox" name="group2" class="check-search" id="theme-5"><label for="theme-5"><span></span>Компании</label> | ||
168 | - </div> | ||
169 | - <div class="blocks-check-list"> | ||
170 | - <input type="checkbox" name="group2" class="check-search" id="theme-6"><label for="theme-6"><span></span>Проектанты</label> | ||
171 | - </div> | ||
172 | - <div class="blocks-check-list"> | ||
173 | - <input checked type="checkbox" name="group2" class="check-search" id="theme-7"><label for="theme-7"><span></span>Все</label> | ||
174 | - </div> | ||
175 | - </div> | ||
176 | - | ||
177 | - | ||
178 | - <a href="#" class="reset-filter">Сбросить фильтр</a> | ||
179 | - <div class="blocks-check-list-submit"> | ||
180 | - <input type="submit" value="Найти"/> | ||
181 | - </div> | ||
182 | - </form> | ||
183 | - */ ?> | ||
184 | </div> | 98 | </div> |
185 | <div class="right-search-work"> | 99 | <div class="right-search-work"> |
186 | <div class="search-worker-title style">Сейчас <?= $dataProvider->totalCount ?> предложений</div> | 100 | <div class="search-worker-title style">Сейчас <?= $dataProvider->totalCount ?> предложений</div> |
@@ -226,7 +140,7 @@ | @@ -226,7 +140,7 @@ | ||
226 | </ul> | 140 | </ul> |
227 | <ul class="min_markers_two"> | 141 | <ul class="min_markers_two"> |
228 | <li><span><img src="/images/markers/marker-min-10.png"/></span> | 142 | <li><span><img src="/images/markers/marker-min-10.png"/></span> |
229 | - <p><?=Yii::t('app', 'projects')?></p></li> | 143 | + <p><?= Yii::t('app', 'projects') ?></p></li> |
230 | <li><span><img src="/images/markers/marker-min-11.png"/></span> | 144 | <li><span><img src="/images/markers/marker-min-11.png"/></span> |
231 | <p>подряды</p></li> | 145 | <p>подряды</p></li> |
232 | </ul> | 146 | </ul> |
@@ -240,12 +154,16 @@ | @@ -240,12 +154,16 @@ | ||
240 | var start_position = new google.maps.LatLng('56', '30'); | 154 | var start_position = new google.maps.LatLng('56', '30'); |
241 | var settings = { | 155 | var settings = { |
242 | zoom : 7, // scrollwheel: false, | 156 | zoom : 7, // scrollwheel: false, |
243 | - center : start_position, mapTypeControl : false, | 157 | + center : start_position, |
158 | + mapTypeControl : false, | ||
244 | mapTypeControlOptions : {style : google.maps.MapTypeControlStyle.DROPDOWN_MENU}, | 159 | mapTypeControlOptions : {style : google.maps.MapTypeControlStyle.DROPDOWN_MENU}, |
245 | navigationControl : false, | 160 | navigationControl : false, |
246 | navigationControlOptions : {style : google.maps.NavigationControlStyle.SMALL}, | 161 | navigationControlOptions : {style : google.maps.NavigationControlStyle.SMALL}, |
247 | - scaleControl : false, streetViewControl : false, rotateControl : false, | ||
248 | - zoomControl : false, mapTypeId : google.maps.MapTypeId.ROADMAP | 162 | + scaleControl : false, |
163 | + streetViewControl : false, | ||
164 | + rotateControl : false, | ||
165 | + zoomControl : false, | ||
166 | + mapTypeId : google.maps.MapTypeId.ROADMAP | ||
249 | }; | 167 | }; |
250 | var map = new google.maps.Map(document.getElementById("map_canvas"), settings); | 168 | var map = new google.maps.Map(document.getElementById("map_canvas"), settings); |
251 | 169 | ||
@@ -308,45 +226,57 @@ | @@ -308,45 +226,57 @@ | ||
308 | 226 | ||
309 | var marker = new google.maps.Marker( | 227 | var marker = new google.maps.Marker( |
310 | { | 228 | { |
311 | - position : new google.maps.LatLng('56', '35.3'), map : map, | ||
312 | - title : 'Marker Title2', icon : image1 | 229 | + position : new google.maps.LatLng('56', '35.3'), |
230 | + map : map, | ||
231 | + title : 'Marker Title2', | ||
232 | + icon : image1 | ||
313 | } | 233 | } |
314 | ); | 234 | ); |
315 | markers.push(marker); | 235 | markers.push(marker); |
316 | 236 | ||
317 | var marker = new google.maps.Marker( | 237 | var marker = new google.maps.Marker( |
318 | { | 238 | { |
319 | - position : new google.maps.LatLng('56', '36'), map : map, | ||
320 | - title : 'Marker Title2', icon : image2 | 239 | + position : new google.maps.LatLng('56', '36'), |
240 | + map : map, | ||
241 | + title : 'Marker Title2', | ||
242 | + icon : image2 | ||
321 | } | 243 | } |
322 | ); | 244 | ); |
323 | markers.push(marker); | 245 | markers.push(marker); |
324 | 246 | ||
325 | var marker = new google.maps.Marker( | 247 | var marker = new google.maps.Marker( |
326 | { | 248 | { |
327 | - position : new google.maps.LatLng('56', '34.5'), map : map, | ||
328 | - title : 'Marker Title3', icon : image18 | 249 | + position : new google.maps.LatLng('56', '34.5'), |
250 | + map : map, | ||
251 | + title : 'Marker Title3', | ||
252 | + icon : image18 | ||
329 | } | 253 | } |
330 | ); | 254 | ); |
331 | markers.push(marker); | 255 | markers.push(marker); |
332 | 256 | ||
333 | var marker = new google.maps.Marker( | 257 | var marker = new google.maps.Marker( |
334 | { | 258 | { |
335 | - position : new google.maps.LatLng('56', '35'), map : map, | ||
336 | - title : 'Marker Title4', icon : image13 | 259 | + position : new google.maps.LatLng('56', '35'), |
260 | + map : map, | ||
261 | + title : 'Marker Title4', | ||
262 | + icon : image13 | ||
337 | } | 263 | } |
338 | ); | 264 | ); |
339 | markers.push(marker); | 265 | markers.push(marker); |
340 | 266 | ||
341 | var clusterStyles = [ | 267 | var clusterStyles = [ |
342 | { | 268 | { |
343 | - url : '/images/markers/clasters.png', height : 36, width : 36 | 269 | + url : '/images/markers/clasters.png', |
270 | + height : 36, | ||
271 | + width : 36 | ||
344 | } | 272 | } |
345 | 273 | ||
346 | ]; | 274 | ]; |
347 | markerClusterer = new MarkerClusterer( | 275 | markerClusterer = new MarkerClusterer( |
348 | map, markers, { | 276 | map, markers, { |
349 | - maxZoom : 10, gridSize : 100, styles : clusterStyles | 277 | + maxZoom : 10, |
278 | + gridSize : 100, | ||
279 | + styles : clusterStyles | ||
350 | } | 280 | } |
351 | ); | 281 | ); |
352 | //балун | 282 | //балун |
@@ -365,6 +295,9 @@ | @@ -365,6 +295,9 @@ | ||
365 | </script> | 295 | </script> |
366 | </div> | 296 | </div> |
367 | <div id="map_canvas" style="width: 100%; height:100%;"></div> | 297 | <div id="map_canvas" style="width: 100%; height:100%;"></div> |
298 | + <?php | ||
299 | + /* Решено убрать нижний слайдер | ||
300 | + ?> | ||
368 | <div class="slider_map-wr"> | 301 | <div class="slider_map-wr"> |
369 | <div class="slider_map_overlay"></div> | 302 | <div class="slider_map_overlay"></div> |
370 | <div class="slider_map"> | 303 | <div class="slider_map"> |
@@ -456,6 +389,9 @@ | @@ -456,6 +389,9 @@ | ||
456 | </div> | 389 | </div> |
457 | </div> | 390 | </div> |
458 | </div> | 391 | </div> |
392 | + <?php | ||
393 | + */ | ||
394 | + ?> | ||
459 | </div> | 395 | </div> |
460 | 396 | ||
461 | </div> | 397 | </div> |