Open
Description
Api Platform is a fast and easy way to add an API.
Initially, it's just installing it and setting the class / property attributes. My datatables bundle uses that, so you can replace
$members = $memberRepository->findByDirectoryCollection($directoryCollection, [
'limit' => $request->get('length', 100),
'offset' => $request->get('start', 0),
'group_by' => $this->getGroupBy($directoryCollection),
'sort_by' => $this->getSortBy($request),
'sort_direction' => $this->getSortDirection($request),
]);
$response = $this->buildDataResponse($members);
with a simple call to the API, which already has limit, offset and sorting. It's pretty cool, I think you'll like it. Plus, you get an API out of it!
Can you add it to the main branch and configure it so that the API works? Then I'll merge it with my branch and use it for the datatables (in a separate controller of course, during testing).
Metadata
Metadata
Assignees
Labels
No labels
Activity