====== Collections ====== ===== What is a Collection? ===== A **Collection** is LEAST's configurable workflow and data engine. Every collection is a self-describing system with: * **Fields (FX)** — the data schema: text, select, date, URL, rating, etc. * **Records (DX)** — the actual data rows * **Interactions (IX)** — a full audit trail of every action taken on every record * **Views (GX)** — named, filtered lenses for reading and writing data Collections power requests, task trackers, content registers, review queues, and more. They are far more than simple lists — each is a mini workflow engine. ===== Creating a Collection ===== - Navigate to an association → **Collections → New Collection** - Enter a name and choose a template (Blank, or a pre-built template like Requests, Jira-style, or GitHub Issues) - The collection is created with the chosen field schema ===== Managing Fields ===== - Open a collection → **Admin → Fields** - Add, reorder, or configure fields - Field types: text, textarea, select, boolean, yes/no, number, date, URL, email, multiselect, currency, rating, colour, lookup ===== Managing Views ===== Views (GX groups) control what records are visible and what fields are shown for different users or purposes: - Open a collection → **Admin → Views** - Each view has: a name, a SQL filter (which records to show), a field list, and API access settings - Views can be set to read-only or read/write for API callers ===== Actions ===== Actions record what happened to a record. Every create, update, and status change is an action: - Open a collection → **Admin → Actions** - Define action names (e.g. "Submitted", "Under Review", "Approved", "Closed") - Actions can have pre-filled field values (e.g. auto-set status to "Closed" when the Approve action is taken) ===== Swim Lanes ===== Collections can be displayed as a Kanban-style swim lane board: - Open collection admin → **Enable Swim Lanes** - Create lane groups (e.g. "To Do", "In Progress", "Done") - Records can be dragged between lanes from the collection view ===== Row-Level Security ===== To restrict records so each user only sees their own: - Open collection admin → **Enable Row-Level Security** - Set the view's RLS mode to **Owner** (each user sees only their records) or **Custom** (SQL filter) - API Admin users bypass RLS and see all records ===== API Access ===== Collections are accessible via the [[developer:api|Collection API]]. Enable API on individual views, set the write action, and share credentials with integrators.