From 3597d712304a42adca5771219a131e1eb708f3bd Mon Sep 17 00:00:00 2001 From: snipe Date: Thu, 7 May 2015 18:21:39 -0700 Subject: [PATCH] Eager load assigned asset locations --- app/controllers/admin/LocationsController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/admin/LocationsController.php b/app/controllers/admin/LocationsController.php index 9d7fa3c0d8..399f1c43a3 100755 --- a/app/controllers/admin/LocationsController.php +++ b/app/controllers/admin/LocationsController.php @@ -23,7 +23,7 @@ class LocationsController extends AdminController public function getIndex() { // Grab all the locations - $locations = Location::orderBy('created_at', 'DESC')->with('parent','assets')->get(); + $locations = Location::orderBy('created_at', 'DESC')->with('parent','assets','assignedassets')->get(); // Show the page return View::make('backend/locations/index', compact('locations'));