| 1 | <?php namespace Arcanesoft\Blog\ViewComposers\Admin\Dashboard; |
||
| 12 | class CommentsCountComposer extends AbstractComposer |
||
| 13 | { |
||
| 14 | /* ----------------------------------------------------------------- |
||
| 15 | | Constants |
||
| 16 | | ----------------------------------------------------------------- |
||
| 17 | */ |
||
| 18 | |||
| 19 | const VIEW = 'blog::admin._composers.dashboard.comments-total-box'; |
||
| 20 | |||
| 21 | /* ----------------------------------------------------------------- |
||
| 22 | | Main Methods |
||
| 23 | | ----------------------------------------------------------------- |
||
| 24 | */ |
||
| 25 | |||
| 26 | /** |
||
| 27 | * Compose the view. |
||
| 28 | * |
||
| 29 | * @param \Illuminate\Contracts\View\View $view |
||
| 30 | */ |
||
| 31 | public function compose(View $view) |
||
| 38 | |||
| 39 | /** |
||
| 40 | * Get the cached comments. |
||
| 41 | * |
||
| 42 | * @return \Illuminate\Database\Eloquent\Collection |
||
| 43 | */ |
||
| 44 | // protected function cachedComments() |
||
| 45 | // { |
||
| 46 | // return $this->cacheResults('comments.all', function () { |
||
| 47 | // return Comment::all(); |
||
| 48 | // }); |
||
| 49 | // } |
||
| 50 | } |
||
| 51 |