We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1ae741b commit 39d2aedCopy full SHA for 39d2aed
src/BlueAdminController.php
@@ -47,6 +47,10 @@ public function api_index($modelname)
47
48
$preloadRelations = array_merge($mapperBelongsTo->pluck('value')->toArray(), $mapperBelongsToMany->pluck('value')->toArray());
49
$model = $this->config->model::with($preloadRelations)->select($modelname.'.*');
50
+
51
+ foreach($this->config->index_scopes as $scope) {
52
+ $model = $model->{$scope}();
53
+ }
54
55
$datatablesObject = DataTables::eloquent($model);
56
0 commit comments