Here's my case. I'm watching an employees page, and want to see projects that employee has been a part of. They can either be attached to a project as a project_leader (can only be 1 employee) or as a contributor (many employees)
{{ collection:projects :project_leader:is="id" OR :people:contains="id" as="entries" }}
{{ if !no_results }}
<div class="flex flex-wrap xl:-mx-12">
{{ entries }}
{{ partial:project-box margin="mb-8" }}
{{ /entries }}
</div>
{{ /if }}
{{ /collection:projects}}
Is this possible in antlers with the collection tag? Couldn't find anything about it.
So, if need to make a custom tag, I have another question. How do i query against an array?
Entry::query()
->where('project_leader', $this->params->get('project_leader'))
->orWhere('contributors', $this->params->get('contributor'));
Thanks, Marius.