Commit de188496b523edaa1215bfeef4a3a290e3a7cd78
1 parent
edf33490
feedback mail 2
Showing
1 changed file
with
26 additions
and
82 deletions
Show diff stats
frontend/views/site/index.php
1 | 1 | <?php |
2 | 2 | |
3 | 3 | /** |
4 | - * @var $this yii\web\View | |
5 | - * @var $slider \common\models\Slider | |
4 | + * @var $this yii\web\View | |
5 | + * @var $slider \common\models\Slider | |
6 | 6 | * @var $objects \common\models\Objectkb |
7 | 7 | */ |
8 | 8 | |
9 | -use common\models\Settings; | |
10 | -use frontend\assets\MapAsset; | |
11 | -use yii\web\View; | |
12 | - | |
13 | -MapAsset::register($this); | |
14 | -$settings = Settings::getInstance(); | |
15 | -$this->title = 'KB Energy'; | |
16 | - | |
17 | -$js = <<< JS | |
9 | + use common\models\Settings; | |
10 | + use frontend\assets\MapAsset; | |
11 | + use yii\web\View; | |
12 | + use yii\helpers\Url; | |
13 | + | |
14 | + MapAsset::register($this); | |
15 | + $settings = Settings::getInstance(); | |
16 | + $this->title = 'KB Energy'; | |
17 | + | |
18 | + $js = <<< JS | |
18 | 19 | window.lat = {$settings->lat}; |
19 | 20 | window.lon = {$settings->lon}; |
20 | 21 | JS; |
21 | - | |
22 | -$this->registerJs($js, View::POS_END); | |
22 | + | |
23 | + $this->registerJs($js, View::POS_END); | |
23 | 24 | ?> |
24 | 25 | |
25 | 26 | <div id="main-page"> |
... | ... | @@ -229,80 +230,18 @@ $this->registerJs($js, View::POS_END); |
229 | 230 | </div> |
230 | 231 | <div class="row"> |
231 | 232 | <div class="col-md-12 col-xs-12" style="text-align:center;margin-top: 20px;margin-bottom: -35px;"> |
232 | - <a href='site/object/' class="button1 more-projects"><?= Yii::t('app', 'sect2_6') ?></a> | |
233 | + <a | |
234 | + href="<?= Url::toRoute(['blog/index'])?>" | |
235 | + class="button1 more-projects" | |
236 | + > | |
237 | + <?= Yii::t('app', 'sect2_6') ?> | |
238 | + </a> | |
233 | 239 | </div> |
234 | 240 | </div> |
235 | 241 | </div> |
236 | 242 | </div> |
237 | 243 | </section> |
238 | 244 | |
239 | -<!-- новый блок с объектами для главной--> | |
240 | -<!-- <section class="bar background-white objects-main-wr">--> | |
241 | -<!-- <div class="container">--> | |
242 | -<!-- <div class="col-md-12">--> | |
243 | -<!-- <div class="heading text-center">--> | |
244 | -<!-- <h2>--><?//=\Yii::t('app', 'index_objects')?><!--</h2>--> | |
245 | -<!-- </div>--> | |
246 | -<!-- <div class="row portfolio">--> | |
247 | -<!-- --><?php | |
248 | -// foreach ($objects as $object) { | |
249 | -// ?> | |
250 | -<!-- <div class="col-sm-6">--> | |
251 | -<!-- <div class="box-image">--> | |
252 | -<!-- <div class="image">--> | |
253 | -<!-- <div class="image_link_wr">--> | |
254 | -<!-- <a href="--><?//=\yii\helpers\Url::toRoute( | |
255 | -// [ | |
256 | -// 'object/view', | |
257 | -// 'alias' => $object->lang->alias, | |
258 | -// ] | |
259 | -// ) ?><!--" class="image_link">--> | |
260 | -<!-- --><?//=$object->image->getImg([])?> | |
261 | -<!-- </a>--> | |
262 | -<!-- </div>--> | |
263 | -<!-- <div class="img-title">--> | |
264 | -<!-- <table>--> | |
265 | -<!-- <tr>--> | |
266 | -<!-- <td class="buts text-left">--> | |
267 | -<!-- <a href="--><?//=\yii\helpers\Url::toRoute( | |
268 | -// [ | |
269 | -// 'object/view', | |
270 | -// 'alias' => $object->lang->alias, | |
271 | -// ] | |
272 | -// ) ?><!--" class="sqre_btn blue_arrow" alt="--><?//=$object->lang->object_name?><!--"></a>--> | |
273 | -<!-- <a href="#" class="btn sqre_btn yellow_calc modaled init-button-сalculate" data-title="Заказать консультацию" data-toggle="modal" data-target="#feedback-modal"></a>--> | |
274 | -<!-- </td>--> | |
275 | -<!-- <td class="i-title" valign="center">--> | |
276 | -<!-- <p class="pr_title2">--> | |
277 | -<!-- <a href="--><?//=\yii\helpers\Url::toRoute( | |
278 | -// [ | |
279 | -// 'object/view', | |
280 | -// 'alias' => $object->lang->alias, | |
281 | -// ] | |
282 | -// ) ?><!--">--> | |
283 | -<!-- --><?//=$object->lang->object_name?> | |
284 | -<!-- </a>--> | |
285 | -<!-- </p>--> | |
286 | -<!-- </td>--> | |
287 | -<!-- </tr>--> | |
288 | -<!-- </table>--> | |
289 | -<!-- </div>--> | |
290 | -<!-- </div>--> | |
291 | -<!-- </div>--> | |
292 | -<!-- </div>--> | |
293 | -<!-- --><?php | |
294 | -// } | |
295 | -// ?> | |
296 | -<!-- </div>--> | |
297 | -<!-- <div class="row">--> | |
298 | -<!-- <div class="col-md-12 col-xs-12" style="text-align:center;margin-top: 20px;margin-bottom: -35px;">--> | |
299 | -<!-- <a href='site/object/' class="button1 more-projects">--><?//= Yii::t('app', 'sect2_6') ?><!--</a>--> | |
300 | -<!-- </div>--> | |
301 | -<!-- </div>--> | |
302 | -<!-- </div>--> | |
303 | -<!-- </div>--> | |
304 | -<!-- </section>--> | |
305 | - | |
306 | 245 | <section class="blue-fon no-mg economy-wr"> |
307 | 246 | <div class="container"> |
308 | 247 | <div class="heading text-center"> |
... | ... | @@ -403,7 +342,12 @@ $this->registerJs($js, View::POS_END); |
403 | 342 | </div> |
404 | 343 | </div> |
405 | 344 | <div class="col-md-12 col-xs-12" style="text-align:center;margin-top: 20px;margin-bottom: -35px;"> |
406 | - <a href="site/object/" class="button1 more-projects"><?=\Yii::t('app', 'more_about_ours')?></a> | |
345 | + <a | |
346 | + href="<?= Url::toRoute(['blog/index'])?>" | |
347 | + class="button1 more-projects" | |
348 | + > | |
349 | + <?=\Yii::t('app', 'more_about_ours')?> | |
350 | + </a> | |
407 | 351 | </div> |
408 | 352 | </div> |
409 | 353 | </section> | ... | ... |