This commit is contained in:
2023-10-04 13:32:30 +03:00
parent 215d238505
commit 1ca5f4e521
82 changed files with 519 additions and 1889 deletions
+2 -6
View File
@@ -15,7 +15,6 @@ use function Lucent\Response\ok;
class HomeController extends Controller
{
public function __construct(
private readonly ChannelService $channelService,
private readonly Svelte $svelte,
private readonly UserRepo $userRepo,
private readonly Query $query,
@@ -45,7 +44,7 @@ class HomeController extends Controller
$limit = 30;
$queryResult = $this->query
$graph = $this->query
->filter($arguments)
->limit($limit)
->childrenDepth(1)
@@ -53,15 +52,12 @@ class HomeController extends Controller
->sort($sort)
->run();
$graph = $queryResult->getQueryRecords();
$users = $this->userRepo->all();
return ok([
"users" => $users,
"records" => $graph->getRootRecords()->toArray(),
"graph" => $graph->toArray(),
"graph" => toArray($graph),
"modalUrl" => $request->fullUrl(),
]);
}