1 | <?php namespace Arcanedev\LogViewer\Tables; |
||
13 | class StatsTable extends AbstractTable |
||
14 | { |
||
15 | /* ------------------------------------------------------------------------------------------------ |
||
16 | | Main Functions |
||
17 | | ------------------------------------------------------------------------------------------------ |
||
18 | */ |
||
19 | /** |
||
20 | * Make a stats table instance. |
||
21 | * |
||
22 | * @param array $data |
||
23 | * @param \Arcanedev\LogViewer\Contracts\Utilities\LogLevels $levels |
||
24 | * @param string|null $locale |
||
25 | * |
||
26 | * @return \Arcanedev\LogViewer\Tables\StatsTable |
||
27 | 72 | */ |
|
28 | public static function make(array $data, LogLevelsContract $levels, $locale = null) |
||
32 | |||
33 | /* ------------------------------------------------------------------------------------------------ |
||
34 | | Other Functions |
||
35 | | ------------------------------------------------------------------------------------------------ |
||
36 | */ |
||
37 | /** |
||
38 | * Prepare table header. |
||
39 | * |
||
40 | * @param array $data |
||
41 | * |
||
42 | * @return array |
||
43 | 144 | */ |
|
44 | protected function prepareHeader(array $data) |
||
54 | |||
55 | /** |
||
56 | * Prepare table rows. |
||
57 | * |
||
58 | * @param array $data |
||
59 | * |
||
60 | * @return array |
||
61 | 144 | */ |
|
62 | protected function prepareRows(array $data) |
||
72 | |||
73 | /** |
||
74 | * Prepare table footer. |
||
75 | * |
||
76 | * @param array $data |
||
77 | * |
||
78 | * @return array |
||
79 | 144 | */ |
|
80 | protected function prepareFooter(array $data) |
||
96 | |||
97 | /** |
||
98 | * Get totals. |
||
99 | * |
||
100 | * @param string|null $locale |
||
101 | * |
||
102 | * @return \Illuminate\Support\Collection |
||
103 | 24 | */ |
|
104 | public function totals($locale = null) |
||
121 | |||
122 | /** |
||
123 | * Get json totals data. |
||
124 | * |
||
125 | * @param string|null $locale |
||
126 | * |
||
127 | * @return string |
||
128 | */ |
||
129 | public function totalsJson($locale = null) |
||
133 | } |
||
134 |