Blame view

frontend/views/article/_article_item.php 971 Bytes
4ca21c3e   Alexey Boroda   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
  <?php
  use common\components\artboximage\ArtboxImageHelper;
  use common\models\Articles;
  use yii\helpers\Url;
  use yii\widgets\ListView;
  /**
   * @var Articles $model
   * @var mixed $key
   * @var integer $index
   * @var ListView $widget
   */
  
  ?>
  
  <div class="note">
      <div class="picture" style="background-image:url('<?php
      echo ArtboxImageHelper::getImageSrc($model->getImageUrl(), 'article_thumb');
      ?>');"></div>
      <div class="text">
          <div class="date"><?php
              echo date('d.m', $model->date);
              if (!empty($model->date_end)) echo ' - ', date('d.m', $model->date_end);
              ?></div>
          <div class="title"><?php echo $model->title; ?></div>
535df954   Eugeny Galkovskiy   123
25
          <div class="text_prev">
4ca21c3e   Alexey Boroda   first commit
26
          <p><?php echo $model->body_preview; ?></p>
535df954   Eugeny Galkovskiy   123
27
          </div>
4ca21c3e   Alexey Boroda   first commit
28
29
30
31
32
          <div class="link_to_cat">
              <a href="<?php echo Url::to(['article/view', 'id' => $model->id]);?>" class="big">Узнать больше</a>
          </div>
      </div>
  </div>