Blame view

thread/modules/news/models/query/ActiveQuery.php 578 Bytes
d1f8bd40   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
  
  namespace thread\modules\news\models\query;
  
  /**
   * Class ActiveQuery
   *
   * @package thread\modules\news\models\query
   * @author FilamentV <vortex.filament@gmail.com>
   * @copyright (c), Thread
   */
  class ActiveQuery extends \thread\app\base\models\query\ActiveQuery
  {
      /**
       * @param int $article_id
       * @return $this
       */
      public function article_id(int $article_id)
      {
          $modelClass = $this->modelClass;
          $this->andWhere($modelClass::tableName() . '.article_id = :article_id', [':article_id' => $article_id]);
          return $this;
      }
  }