Include egg variables in the output from the API
This commit is contained in:
parent
3a2c60ce31
commit
cae604e79d
12 changed files with 204 additions and 92 deletions
|
@ -143,6 +143,10 @@ class ServerRepository extends EloquentRepository implements ServerRepositoryInt
|
|||
*/
|
||||
public function getVariablesWithValues(int $id, bool $returnAsObject = false)
|
||||
{
|
||||
$this->getBuilder()
|
||||
->with('variables', 'egg.variables')
|
||||
->findOrFail($id);
|
||||
|
||||
try {
|
||||
$instance = $this->getBuilder()->with('variables', 'egg.variables')->find($id, $this->getColumns());
|
||||
} catch (ModelNotFoundException $exception) {
|
||||
|
|
Reference in a new issue