/** * @param int|string $instanceId * * @return Instance */ protected static function findInstance($instanceId) { return Instance::with(['user', 'guest'])->byNameOrId($instanceId)->firstOrFail(); }
public function index() { return $this->renderView('app.instances', ['instances' => Instance::with(['user', 'cluster'])->get()]); }