Basker Docs

Conditions and rules

How conditions work in an automated smart collection — fields, operators, and date logic

A condition is a single rule a record must satisfy to be included in a smart collection. Each condition has three parts: a field, an operator, and a value.

A smart collection can combine many conditions. Choose Match all to require every condition to be true, or Match any for at least one.

What fields you can match on

The fields available depend on the target content type. Each type exposes only the fields that are meaningful for it:

  • Events — season, series, venue, start date, end date, and custom attributes.
  • Posts — blog, author, category, tag, publish date, and custom attributes.
  • Pages — title, parent page, template name, and published date.
  • Organizations — organization type (producer or sponsor) and custom attributes.
  • Seasons and series — start date, end date, and custom attributes.
  • People, venues, and works — custom attributes.

When a content type has no fields of its own beyond custom attributes, build your conditions from the custom data fields you've added to it.

The condition editor only offers the fields that apply to the target you've chosen, so the list of fields changes when you switch the target content type.

What operators you can use

Operators express the kind of comparison:

  • is — exact match.
  • is not — exact non-match.
  • more than / fewer than — for date fields (later than / earlier than the value).
  • is in / is not in — match (or exclude) against a list of values, for fields that accept several values such as series, authors, categories, and tags.
  • includes — partial text match, for text fields such as a page title or template name.

Not every operator is meaningful for every field — date operators are only offered on dates, and is in is only offered on fields that take a set of values. The condition editor only shows the operators that apply to the field you've picked.

Working with dates

Date conditions support two modes:

  • Specific date/time — match against a fixed moment ("after 1 January 2026").
  • Relative to now — match against a moving target ("in the next 7 days", "more than 30 days ago").

Relative date conditions are how you build listings that stay current. "Current and upcoming events" is a smart collection of events with an end date more than now; "Recent posts" is a smart collection of posts with a publish date more than now − 30 days (published within the last 30 days).

You can pick a preset — Now, Now + 1 day, Now + 7 days, Now + 30 days, Now − 7 days, or Now − 30 days — or set a custom offset. A custom offset is a number, a unit (minutes, hours, days, or weeks), and a direction (After now or Before now). Offsets can reach up to 365 days.

Start date vs end date for events

If you're building a listing of current and upcoming events, filter on end date more than now, not start date. Start date is in the past for any event that has already opened — a mid-run show with performances still to come will be excluded if you use start date. End date stays in the future for as long as the event is still running.

End date lives on the event record. Keep it up to date so your collections stay accurate.

Building useful conditions

A few patterns that come up often:

  • Upcoming and in-run events — events where end date is after now. This includes events that have already opened but haven't finished, as well as events that haven't started yet. Avoid using start date for this — once a show has opened, its start date is in the past and it will drop out of the collection even if performances are still to come.
  • This season's events — events where season is the current season.
  • Recent posts — posts where publish date is more than now − 30 days.
  • Posts from one author — posts where author is in the chosen people.
  • Sponsors — organizations where organization type is sponsor.
  • Featured by tag — posts where tag is in a chosen set.
  • By custom attribute — any content type with custom data, where a custom attribute is (or is in) a chosen value. Pick Custom Attribute as the field, choose which attribute, then set the value.

Combine multiple conditions with Match all to narrow further: "events in the current season, at the main venue, in the next 14 days".

Only published records are listed

A smart collection's public page lists published records only — drafts and scheduled records appear in the draft preview but not on the live site. Once a matching record is published, it appears in the listing automatically.

Where to go next

On this page