Add all of the potential transformers that might be needed for now.
This commit is contained in:
parent
65630bdcce
commit
51204b8d9d
12 changed files with 642 additions and 9 deletions
|
@ -64,10 +64,7 @@ class ServerController extends Controller
|
|||
$fractal = Fractal::create()->item($server);
|
||||
|
||||
if ($request->input('include')) {
|
||||
$fractal->parseIncludes(collect(explode(',', $request->input('include')))->intersect([
|
||||
'allocations', 'subusers', 'user',
|
||||
'pack', 'service', 'option',
|
||||
])->toArray());
|
||||
$fractal->parseIncludes(explode(',', $request->input('include')));
|
||||
}
|
||||
|
||||
return $fractal->transformWith(new ServerTransformer)
|
||||
|
|
|
@ -47,9 +47,7 @@ class ServerController extends Controller
|
|||
$fractal = Fractal::create()->item($server);
|
||||
|
||||
if ($request->input('include')) {
|
||||
$fractal->parseIncludes(collect(explode(',', $request->input('include')))->intersect([
|
||||
'allocations', 'subusers', 'stats',
|
||||
])->toArray());
|
||||
$fractal->parseIncludes(explode(',', $request->input('include')));
|
||||
}
|
||||
|
||||
return $fractal->transformWith(new ServerTransformer)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue