Open wesort opened 2 days ago
I was thinking this might be a good use case for a custom field condition to query against the slug
and makes this a bit more readable, but that probably doesn't work since the data inside the conditions would be just the id, right? So no way to query the slug without major contortions.
Following on from this Discord thread, I found it unintuitive how to conditionally show/hide fields based on the value of an
Entries
field. I tried the docs for Conditional Fields, but it doesn't include this.Context
Archive
has an entries field calledArchive type
which allows users to select1
(max items) entry from another collection calledArchive type
Archive
blueprint, I need to show/hide fields based on what the user choose inArchive type
.Video
, then show the fieldVideo meta info
Photo
, then hide the fieldVideo meta info
Condition that does not work
equals video
, but this doesn't work.contains
,===
, prepending with$root
andcollection::archive_type::
Solution / Workaround
ID
of theArchive type
entry ofVideo
and usecontains
orcontains_any
(comma separating theID
s)