Пример #1
0
 /**
  * Make query to database
  * @return object
  */
 private function makeQuery()
 {
     return Content::select(['contents.*', 'content_categories.path as cpath', 'content_categories.title as ctitle'])->whereIn('contents.category_id', $this->categories)->join('content_categories', 'content_categories.id', '=', 'contents.category_id', 'left outer')->orderBy('contents.created_at', 'DESC')->take($this->count)->get();
 }