Closed
Description
Description
Unable to order entries based on the order the slugs are received.
Steps to reproduce
- Copy below entries.json and view the entries.json output in the browser.
- Order will be the same regardless of how the slugs are ordered.
Additional info
return [
'endpoints' => [
'entries.json' => function() {
$slugs = Craft::$app->getRequest()->getRequiredQueryParam('slugs');
return [
'elementType' => Entry::class,
'criteria' => [
'slug' => $slugs
],
'transformer' => function (Entry $entry) {
return [
"title" => $entry->title,
];
},
];
}
]
]
- Craft version: 4.9.0
- PHP version: 8.1.27
- Database driver & version: MySQL 8.0.33
- Plugins & versions: Element-api 4.1.0