Skip to content

Lists

A list view is one resource’s rows, narrowed by a standing query and the reader’s tab, filters and sort.

leads: listView('Leads', 'lead', {
show: ['name', 'company', 'status', 'owner_id.name', 'created_on'],
filters: ['status', 'source', 'created_on'],
sort: 'created_on desc',
tabs: [
{ label: 'New', query: 'status = new' },
{ label: 'Working', query: 'status = working', sort: 'name' },
{ label: 'All' },
],
}),
Key Says
query Standing conditions every tab refines.
tabs { label, query?, sort? } in order; the first opens. A tab’s sort is its own order (Upcoming soonest first). The address names the open one (?tab=working).
show Columns and label paths (owner_id.name); a reference is drawn by its record’s name.
filters Columns offered as filter boxes; filterBar: 'rail' draws them as facets beside the rows.
sort The order when nothing else says one. A tab’s own sort wins over it, the Sort menu over both.
sorts { label, sort } choices for a Sort menu.
order A numeric column holding each row’s place: rows read in it, and a reader who may write it drags them.
totals Numeric columns summed in a footer, over everything the list matches. A grid only.
presentation How rows draw: absent is a grid; checklist, queue, board, split, calendar and cards (the last two in preview), or a custom list. A card’s fact can say a word after its value: { column: 'owners', label: 'owner' } reads “1 owner”, “3 owners”; position: 'before' puts it first.
editable, rowActions, open, quickAdd, density Cells edited in place, a row’s own actions, peek or modal, an inline New form, compact rows.

A column header’s menu is short: the two sorts in the column’s words (A → Z, Low → high, Oldest first), one Filter… that opens the control the filter rail draws for the column (or goes to the rail’s own, beside the rows), Clear filter while it narrows the list, and Pin column, which is the reader’s own for this list. Starts with, a pattern, empty and not empty sit behind More conditions in that control and in every rail facet. The standalone database browser keeps its full menu.

A tab’s query and a view’s query are the query language without the table name: conditions joined by and, or and parentheses, then an optional sort.

Intent Spelling
Compare =, !=, <, <=, >, >=
Text contains, startswith, endswith
A set in (new, working), not in (…)
Empty is empty, is not empty
Dates today, this week, last month, last 30 days, next 90 days
Through a reference account_id.rating = hot
Order sort close_date desc, name

A name the catalog does not have is refused at load, never an empty tab. The whole grammar, grouping included: Query language & MCP. Every key of a list: DSL reference.