mirror of
https://github.com/CachetHQ/Cachet.git
synced 2025-03-14 20:39:44 +01:00
Paginate the points API for metrics
This commit is contained in:
parent
69fe2d7b3a
commit
01e40c4684
@ -55,7 +55,9 @@ class MetricController extends AbstractApiController
|
||||
*/
|
||||
public function getMetricPoints(Metric $metric)
|
||||
{
|
||||
return $this->collection($metric->points);
|
||||
$points = $metric->points()->paginate(Binput::get('per_page', 20));
|
||||
|
||||
return $this->paginator($points, Request::instance());
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user