Eager load the metric points.
This commit is contained in:
@@ -59,6 +59,13 @@ class Metric extends Model implements HasPresenter
|
|||||||
*/
|
*/
|
||||||
protected $fillable = ['name', 'suffix', 'description', 'display_chart', 'default_value', 'calc_type'];
|
protected $fillable = ['name', 'suffix', 'description', 'display_chart', 'default_value', 'calc_type'];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The relations to eager load on every query.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $with = ['points'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Metrics contain many metric points.
|
* Metrics contain many metric points.
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user