@@ 180-189 (lines=10) @@ | ||
177 | /** |
|
178 | * @SuppressWarnings(PHPMD.ShortVariable) |
|
179 | */ |
|
180 | public function find($id, $columns = ['*']) |
|
181 | { |
|
182 | $tags = $this->getCacheTags(); |
|
183 | $key = $this->getCacheKey($columns, $id); |
|
184 | ||
185 | return $this->cache($tags) |
|
186 | ->rememberForever($key, function () use ($id, $columns) { |
|
187 | return parent::find($id, $columns); |
|
188 | }); |
|
189 | } |
|
190 | ||
191 | public function first($columns = ['*']) |
|
192 | { |
|
@@ 191-200 (lines=10) @@ | ||
188 | }); |
|
189 | } |
|
190 | ||
191 | public function first($columns = ['*']) |
|
192 | { |
|
193 | $tags = $this->getCacheTags(); |
|
194 | $key = $this->getCacheKey($columns) . '-first'; |
|
195 | ||
196 | return $this->cache($tags) |
|
197 | ->rememberForever($key, function () use ($columns) { |
|
198 | return parent::first($columns); |
|
199 | }); |
|
200 | } |
|
201 | ||
202 | public function get($columns = ['*']) |
|
203 | { |
|
@@ 202-211 (lines=10) @@ | ||
199 | }); |
|
200 | } |
|
201 | ||
202 | public function get($columns = ['*']) |
|
203 | { |
|
204 | $tags = $this->getCacheTags(); |
|
205 | $key = $this->getCacheKey($columns); |
|
206 | ||
207 | return $this->cache($tags) |
|
208 | ->rememberForever($key, function () use ($columns) { |
|
209 | return parent::get($columns); |
|
210 | }); |
|
211 | } |
|
212 | ||
213 | public function max($column) |
|
214 | { |