I’m trying to create a filter for moderation equal to Draft.
It doesn’t seem to work in any way, it always recovers the entry with published = published (perhaps from the first revision).
$project = cockpit('collections')->find('projects_custom_preview', [ 'filter' => [ 'previewId' => $_GET['previewId'], 'permalink' => $_GET['permalink'], 'published' => 'Draft', ] ]);
I added an entry in the collection:
previewId = 123
permalink = test
title = title test
Except in public mode, I later change the title to test 2 title.
In the database it is correct with draft mode and title test 2 title but the above query always shows me the data with title equal to test title.