pgkiln 0.37.0 → 0.38.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/SECURITY.md CHANGED
@@ -69,6 +69,7 @@ first version (MVP). Every finding below has a regression test in
69
69
  | App Builder AI and blueprints (0.28.0) | Developer session and CSRF; only administrators choose the builder's AI service. Generated SQL is shown, never run automatically; page proposals are checked (page types, tables the app role can read, free page numbers) and created only after the developer confirms. The model sees names, types and keys, never rows. A blueprint is validated (identifiers, references, rows) and turned into quoted SQL; Create only accepts the exact text the review showed, signed with the developer's session, in one transaction. `meta.builder_ai`, `meta.ai_table_note` and `meta.blueprint` are closed to the runtime role. |
70
70
  | Workspaces (0.29.0) | Every builder request under `/apps/:id` or `/pages/:pid` (GET and POST), a working copy's main application, a boilerplate and the code editor's application are checked against the developer's workspaces in `developer()` and answer 404 outside them; lists are filtered by the current workspace. Switching needs CSRF and membership; managing workspaces needs an administrator and CSRF; names are escaped; subscriptions only reach theme and library applications of the same workspace. Workspace tables are closed to the runtime role. **A shared workspace is not a tenant boundary:** its SQL Workshop runs as the owner and its application code on the shared runtime connection; isolate a workspace for that (below). |
71
71
  | Isolated workspaces (sprint 60) | The boundary is the PostgreSQL login (`session_user`, which SQL can't change): an isolated workspace's applications run on its own run login and its developers' SQL on its own developer login (`src/workspace-db.ts`; passwords derived from `PGKILN_SECRET_KEY`, never stored), so `RESET ROLE` or `set_config('role', …)` only reach that login. The run login has `pgkiln_app_code` (the runtime role's rights in `meta`, kept in step after every migration by `meta.sync_app_code_grants()`, checked by a test) and the workspace's roles; the developer login only the workspace's roles. Row-level security on every `meta` table the runtime reads keys on the login (`meta.visible_apps()`), both ways: isolated workspaces don't see others, the shared runtime doesn't see isolated ones; the owner isn't affected. `meta.app_id()` and the eight functions that take an application id (`meta.checked_app`) refuse an application the login may not see. A workspace's database roles are an administrator's list (`meta.workspace_role`): an application there may only run as one of them, a role belongs to one workspace, and superusers, roles with CREATEROLE/BYPASSRLS/REPLICATION and pgkiln's own roles are refused; memberships follow by triggers (`meta.workspace_sync_roles()`). A new application gets a new role and a new or own schema. Every builder tool that runs a developer's SQL uses the workspace's developer login (`workshopDb`, `devDbForApp`); the import check plans the imported SQL on it, outside the import's owner transaction. Saved scripts, runs, blueprints and generators are per workspace. **Not covered:** administrators and developers who also belong to a shared workspace (owner rights there), the `pg_catalog` (definitions are readable by every login), PostgREST (one authenticator), identity providers, LDAP, mail and AI services (installation-wide). |
72
+ | Builder screens like APEX's (sprint 61) | The sign-in page's workspace is checked after the password (only the developer's workspaces; a wrong one answers like a wrong password, failures are throttled and logged as before); *Remember workspace and username* is an HttpOnly cookie for `/builder` holding no secret, read defensively and escaped; the redirect after sign-in is a `/builder` path only. Workspace message and banner: administrators and the workspace's administrators, CSRF, plain text escaped, the banner colour from a fixed list. Utilization: the same. SQL Workshop home: your own recent commands only (by id and username), the schema checked against the schemas the session's connection may use (and set as a parameter of `set_config`). Application groups: every query bound to the current workspace; groups and applications of other workspaces are ignored. App Gallery: keys are names from `examples/gallery/gallery.json`, never paths; sample apps (shipped SQL as the owner, demo accounts with known passwords) are for administrators only; starter apps go through the blueprint review and its signed create step. Cross application reports: fixed SQL per topic, the workspace id as a parameter. |
72
73
  | Drawers, built-in template components, Theme Roller additions (0.29.0) | Dialog positions and sizes, base styles, dark-mode colours, item and report-column template options only reach the page from fixed lists (checked when saved and again when rendered: a hand-edited value is ignored); the browser gets dialog shapes as JSON values from those lists. Built-in template components pass the same template checks as plug-ins; *Copy into this application* takes a static id from the fixed list, needs CSRF and the application in the developer's workspace, and never overwrites the application's own component. |
73
74
  | Report row selection across pages (0.29.0) | `POST …/report/<id>/select` needs the CSRF token, page access and a visible report region whose `selection` names the item (and the item visible); it only changes that item's session state; values are bounded (5000, 400 characters, no `:`) and treated as user input, like a submit; output is escaped. |
74
75
  | Instance settings (0.29.0) | Administrators only, with CSRF; only whole numbers within each setting's range are stored (a bad stored value falls back to the environment variable or default); the configuration overview never shows secrets (connection strings, keys: only whether they are set); changes are logged.
@@ -0,0 +1,20 @@
1
+ -- =====================================================================
2
+ -- 091: a workspace's message and environment banner (APEX: Administration
3
+ -- → Manage Service → Define Workspace Message, Define Environment Banner)
4
+ --
5
+ -- message shown to the workspace's developers on the App Builder home
6
+ -- (plain text, at most 2000 characters)
7
+ -- banner_label a short label (e.g. DEVELOPMENT, TEST) shown in a coloured band
8
+ -- at the top of every builder page while the workspace is current
9
+ -- banner_color one colour of a fixed list (the builder's CSS draws them)
10
+ --
11
+ -- Administrators and the workspace's administrators set them.
12
+ -- Installation data, not exported.
13
+ -- =====================================================================
14
+ alter table meta.workspace
15
+ add column message text check (length(message) between 1 and 2000),
16
+ add column banner_label text check (banner_label ~ '^\S(.{0,38}\S)?$'),
17
+ add column banner_color text not null default 'blue'
18
+ check (banner_color in ('red', 'orange', 'yellow', 'green', 'teal', 'blue', 'purple', 'gray'));
19
+ comment on column meta.workspace.message is 'Workspace message (091): shown to its developers on the App Builder home.';
20
+ comment on column meta.workspace.banner_label is 'Environment banner (091): a label shown at the top of the builder while the workspace is current.';
@@ -0,0 +1,23 @@
1
+ -- =====================================================================
2
+ -- 092: application groups (APEX: Workspace Utilities → Application Groups)
3
+ --
4
+ -- A workspace's named groups of applications, to organise the App Builder:
5
+ -- the home page filters and labels applications by group. They change
6
+ -- nothing at run time. Installation data (like workspaces): not exported,
7
+ -- kept by an in-place import.
8
+ -- =====================================================================
9
+ create table meta.app_group (
10
+ id serial primary key,
11
+ workspace_id int not null references meta.workspace on delete cascade,
12
+ name text not null check (name ~ '^\S(.{0,58}\S)?$'),
13
+ description text check (length(description) <= 2000),
14
+ unique (workspace_id, name)
15
+ );
16
+ create table meta.app_group_member (
17
+ app_id int primary key references meta.app on delete cascade,
18
+ group_id int not null references meta.app_group on delete cascade
19
+ );
20
+ create index app_group_member_group_idx on meta.app_group_member (group_id);
21
+ revoke all on meta.app_group, meta.app_group_member from public;
22
+ comment on table meta.app_group is 'Application groups (092): a workspace''s named groups of applications, for the App Builder. Not exported.';
23
+ comment on table meta.app_group_member is 'The group of an application (092); none: ungrouped.';
@@ -7,13 +7,13 @@ open item and open an issue or pull request; see [CONTRIBUTING.md](../CONTRIBUTI
7
7
  Legend: ✅ available · 🟡 partial (see notes) · ❌ not yet · ➖ not planned (a deliberate choice,
8
8
  or better served by the PostgreSQL ecosystem; see the notes and [extensions](guide/15-extensions.md))
9
9
 
10
- Last reviewed: 2026-10-13 (sprint 60: isolated workspaces with their own database logins, row-level security on pgkiln's tables and workspace database roles, workspace administrators; sprint 59: the Page Designer's help pane, Quick edit from the developer toolbar; sprint 58: page groups; sprint 57: region templates hero, title bar, buttons container, inline dialog and drawer, wizard with wizard progress, the carousel; sprint 56: Generate DDL and Schema Comparison in the SQL Workshop, `pgkiln ddl` and `pgkiln compare`; sprint 55: an editable login page with a Login region and the Minimal page template, Forgot password through the application's mail service; sprint 54: interactive grid views, the single row view, group by and chart; sprint 53: application settings, user preferences and items kept per user, dynamic translations, `meta.data_export` and data export downloads, display image and geocoded address items; sprint 52: every dynamic action event and action, Ajax callbacks, an error handling function, the session timeout warning; sprint 51: checked imports, application backups, availability and Run only, feedback, type-specific attribute help; sprint 50: lost update detection, warn on unsaved changes, the URL and search regions with search configurations, the developer toolbar with a session state viewer, and e-mail through SMTP with OAuth2, Microsoft Graph, Amazon SES and HTTP APIs; import checks, application availability, property help and e-mail compared again; 2026-10-06: pgkiln 0.31.0, in progress: static application files and the Execute JavaScript dynamic action; region, item, dynamic action and process plug-ins; conditional and dynamic theme styles; XML and Excel in `meta.parse_data`, zips in SQL, `meta.v_boolean`; file items in S3-compatible object storage; map layers by the visible area and as vector tiles; a graphical query builder; tenants for workflows and tasks; application files as YAML and region static IDs; Lucide icons and icon modifiers; PWA push notifications; 0.30.0: 136 icons and an icon picker; an axe-core accessibility audit; cropping pictures; session sharing between applications; twenty-two built-in languages; 0.29.0: workspaces; the Iris base style; drawers; built-in template components including the metric card; Theme Roller dark-mode colours, live preview and template options on items and report columns; report selection across pages; instance settings; fourteen built-in languages; 0.28.0: AI with Claude and OpenAI; 0.27.0: Data Reporter; sample data generator; create application from several sheets, pasted data or existing tables; 0.26.0: working copies with a three-way merge; theme, library and boilerplate applications with subscriptions; 0.25.0: Gantt, pyramid and polar charts; map layers, clustering and server-side spatial filters; REST data sources that write back from forms and grids and synchronise into tables, OAuth2 password and refresh-token grants; debug messages per request and an install/upgrade log; `meta.web_request()` and `meta.parse_data()`; Theme Roller style variants and template options; 0.24.0: automations with several actions, error handling per row and runs from SQL; invoke-API workflow steps; Unload Data in the Data Workshop; create page wizards for cards, calendar, chart, map, faceted search, form and master-detail; create an application from a file; 0.23.0: interactive grid aggregates, frozen/moved/resized columns, layouts and saved grid reports, master-detail, row actions and copy/paste; download processes, execution chains in the background, workflow processes, branches to a function's URL or another app, the Dialog Closed event; number format masks, automatic time zone, runtime messages in German, French and Spanish; SQL scripts, Quick SQL, a query builder, XML loading and data load definitions; custom authentication, lists, page and application locks with developer comments, supporting objects; 0.22.0: keyset paging, report PDFs and REST collections streamed from a cursor, database-account authentication; 0.21.0: HTTP-header authentication behind a reverse proxy; 0.20.0: a popup list of values with server-side search; 0.19.0: row-range pagination, maximum row counts and row limits, lazy loading and caching of regions, streamed CSV/Excel downloads; 0.18.0: calendar week/day/list views with drag and drop, bubble/gauge/funnel/radar charts and drill-down, smart filters, a region display selector and more facet types, computations, conditional branches, build options, menu buttons, REST data sources and web credentials, rich text/Markdown, rating, combobox, date range and QR code items; 0.17.0: an App Builder home, workspace dashboard and utilities like APEX's; 0.16.0: a Page Designer with drag-and-drop layout, a code editor with autocomplete, template components and plug-ins, parallel branches and versions of workflows, the `pgkiln` command line with one file per component; 0.15.0: drop and paste files, heat maps, filtering a report by the map area; 0.14.0: stacked, combo, scatter and pie charts, several files per upload item; 0.13.0: map and tree regions; 0.12.0: REST modules in the builder; 0.11.0: workflows and Progressive Web Apps; 0.10.0: LDAP, SAML, "Keep me signed in", document templates, JSON loading, approvals and the task list; pgkiln installs no application, HR is an example).
10
+ Last reviewed: 2026-10-13 (sprint 61: the builder's screens compared with APEX 26.1: the workspace sign-in page, the Administration menu with workspace message, environment banner and utilization, the SQL Workshop home, the App Gallery, application groups and cross application reports (four rows added); sprint 60: isolated workspaces with their own database logins, row-level security on pgkiln's tables and workspace database roles, workspace administrators; sprint 59: the Page Designer's help pane, Quick edit from the developer toolbar; sprint 58: page groups; sprint 57: region templates hero, title bar, buttons container, inline dialog and drawer, wizard with wizard progress, the carousel; sprint 56: Generate DDL and Schema Comparison in the SQL Workshop, `pgkiln ddl` and `pgkiln compare`; sprint 55: an editable login page with a Login region and the Minimal page template, Forgot password through the application's mail service; sprint 54: interactive grid views, the single row view, group by and chart; sprint 53: application settings, user preferences and items kept per user, dynamic translations, `meta.data_export` and data export downloads, display image and geocoded address items; sprint 52: every dynamic action event and action, Ajax callbacks, an error handling function, the session timeout warning; sprint 51: checked imports, application backups, availability and Run only, feedback, type-specific attribute help; sprint 50: lost update detection, warn on unsaved changes, the URL and search regions with search configurations, the developer toolbar with a session state viewer, and e-mail through SMTP with OAuth2, Microsoft Graph, Amazon SES and HTTP APIs; import checks, application availability, property help and e-mail compared again; 2026-10-06: pgkiln 0.31.0, in progress: static application files and the Execute JavaScript dynamic action; region, item, dynamic action and process plug-ins; conditional and dynamic theme styles; XML and Excel in `meta.parse_data`, zips in SQL, `meta.v_boolean`; file items in S3-compatible object storage; map layers by the visible area and as vector tiles; a graphical query builder; tenants for workflows and tasks; application files as YAML and region static IDs; Lucide icons and icon modifiers; PWA push notifications; 0.30.0: 136 icons and an icon picker; an axe-core accessibility audit; cropping pictures; session sharing between applications; twenty-two built-in languages; 0.29.0: workspaces; the Iris base style; drawers; built-in template components including the metric card; Theme Roller dark-mode colours, live preview and template options on items and report columns; report selection across pages; instance settings; fourteen built-in languages; 0.28.0: AI with Claude and OpenAI; 0.27.0: Data Reporter; sample data generator; create application from several sheets, pasted data or existing tables; 0.26.0: working copies with a three-way merge; theme, library and boilerplate applications with subscriptions; 0.25.0: Gantt, pyramid and polar charts; map layers, clustering and server-side spatial filters; REST data sources that write back from forms and grids and synchronise into tables, OAuth2 password and refresh-token grants; debug messages per request and an install/upgrade log; `meta.web_request()` and `meta.parse_data()`; Theme Roller style variants and template options; 0.24.0: automations with several actions, error handling per row and runs from SQL; invoke-API workflow steps; Unload Data in the Data Workshop; create page wizards for cards, calendar, chart, map, faceted search, form and master-detail; create an application from a file; 0.23.0: interactive grid aggregates, frozen/moved/resized columns, layouts and saved grid reports, master-detail, row actions and copy/paste; download processes, execution chains in the background, workflow processes, branches to a function's URL or another app, the Dialog Closed event; number format masks, automatic time zone, runtime messages in German, French and Spanish; SQL scripts, Quick SQL, a query builder, XML loading and data load definitions; custom authentication, lists, page and application locks with developer comments, supporting objects; 0.22.0: keyset paging, report PDFs and REST collections streamed from a cursor, database-account authentication; 0.21.0: HTTP-header authentication behind a reverse proxy; 0.20.0: a popup list of values with server-side search; 0.19.0: row-range pagination, maximum row counts and row limits, lazy loading and caching of regions, streamed CSV/Excel downloads; 0.18.0: calendar week/day/list views with drag and drop, bubble/gauge/funnel/radar charts and drill-down, smart filters, a region display selector and more facet types, computations, conditional branches, build options, menu buttons, REST data sources and web credentials, rich text/Markdown, rating, combobox, date range and QR code items; 0.17.0: an App Builder home, workspace dashboard and utilities like APEX's; 0.16.0: a Page Designer with drag-and-drop layout, a code editor with autocomplete, template components and plug-ins, parallel branches and versions of workflows, the `pgkiln` command line with one file per component; 0.15.0: drop and paste files, heat maps, filtering a report by the map area; 0.14.0: stacked, combo, scatter and pie charts, several files per upload item; 0.13.0: map and tree regions; 0.12.0: REST modules in the builder; 0.11.0: workflows and Progressive Web Apps; 0.10.0: LDAP, SAML, "Keep me signed in", document templates, JSON loading, approvals and the task list; pgkiln installs no application, HR is an example).
11
11
 
12
12
  ## At a glance
13
13
 
14
14
  | Area | ✅ | 🟡 | ❌ | ➖ | In short |
15
15
  |---|---:|---:|---:|---:|---|
16
- | App Builder and development | 17 | 0 | 0 | 0 | Page Designer with drag-and-drop and a code editor, wizards, search, where used, an Advisor, a CLI with one file per component, page locks and comments, supporting objects, working copies with a three-way merge, theme/library/boilerplate apps with subscriptions; App Builder AI (pages, SQL and table descriptions) |
16
+ | App Builder and development | 20 | 0 | 0 | 0 | Page Designer with drag-and-drop and a code editor, wizards, search, where used, an Advisor, a CLI with one file per component, page locks and comments, supporting objects, working copies with a three-way merge, theme/library/boilerplate apps with subscriptions; App Builder AI (pages, SQL and table descriptions) |
17
17
  | Regions | 23 | 0 | 0 | 0 | All everyday regions, a search region over search configurations and a URL region; sixteen chart types with drill-down; calendars with week/day/list views and drag and drop; faceted search, smart filters and a region display selector; interactive reports with breaks, aggregates, highlights, compute, group by, pivot, chart view and saved reports; interactive grids with single row, group by and chart views; maps (with vector tiles) and trees; template components; row ranges, lazy loading and region caching for large tables |
18
18
  | Items | 13 | 0 | 0 | 0 | All common items, file upload (several files per item), rich text and Markdown editors, star rating, combobox, date range, QR code, password reveal, display image and geocoded address |
19
19
  | Logic and processing | 17 | 0 | 0 | 1 | User preferences and application settings; all dynamic action events and actions, Ajax callbacks and an error handling function; Core APEX model complete with computations, conditional branches, build options and menu buttons, download, chain and workflow processes; JavaScript from static application files in dynamic actions; region, item, dynamic action and process plug-ins |
@@ -22,12 +22,13 @@ Last reviewed: 2026-10-13 (sprint 60: isolated workspaces with their own databas
22
22
  | Globalization | 6 | 0 | 0 | 0 | One translated app like 26.1 with dynamic translations of table values; number format masks and automatic time zone; twenty-two built-in languages |
23
23
  | Data and integration | 12 | 0 | 0 | 2 | Generate DDL and schema comparison; `meta.data_export` and data export downloads (CSV, JSON, XML, HTML, Excel, PDF); e-mail through SMTP (password or OAuth2), Microsoft Graph, Amazon SES and HTTP APIs; REST APIs via PostgREST, REST data sources that write back and synchronise, web credentials with OAuth2 grants, CSV/XLSX/JSON/XML loading with saved definitions and unloading, SQL scripts and Quick SQL, report PDFs and document templates |
24
24
  | Workflow, automation and AI | 6 | 0 | 0 | 0 | Scheduled automations with several actions and runs from SQL, approvals, a task list and workflows with parallel branches, versions and invoke-API steps; AI with Claude or OpenAI: *Generate text with AI*, an assistant region with tools, natural-language report filters and blueprints |
25
- | Administration | 9 | 0 | 0 | 0 | Isolated workspaces with their own database logins and roles, and workspace administrators; application availability and Run only, automatic backups, user feedback; a developer toolbar with a session state viewer and debug per session; Top SQL per app; debug messages per request; an install/upgrade log |
26
- | **Total** | **137** | **0** | **0** | **3** | 140 APEX features compared: 98% available, none partial or missing |
25
+ | Administration | 10 | 0 | 0 | 0 | An APEX-like sign-in with a workspace; workspace message, environment banner and utilization; isolated workspaces with their own database logins and roles, and workspace administrators; application availability and Run only, automatic backups, user feedback; a developer toolbar with a session state viewer and debug per session; Top SQL per app; debug messages per request; an install/upgrade log |
26
+ | **Total** | **141** | **0** | **0** | **3** | 144 APEX features compared: 98% available, none partial or missing |
27
27
 
28
28
  (Counts are of the rows in the tables below. A review on 2026-10-06 added 18 rows for APEX features that were
29
- not compared before, and one on 2026-10-12 added two more (property help, application availability), so the share
30
- available dropped without anything being removed.)
29
+ not compared before, one on 2026-10-12 added two more (property help, application availability), and one on
30
+ 2026-10-13 compared the builder's screens with APEX 26.1 and added four (App Gallery, application groups, cross
31
+ application reports, Manage Service), so the share available dropped without anything being removed.)
31
32
 
32
33
  ## App Builder and development
33
34
 
@@ -50,6 +51,9 @@ available dropped without anything being removed.)
50
51
  | Builder search, "where used" | ✅ | Search over every page and component (names, SQL, settings, help); "Used in" under items, pages, lists of values, schemes and report layouts. No search and replace |
51
52
  | AI assistant, pages from natural language, describe tables for LLMs (26.1) | ✅ | **App Builder AI** (administrators choose the builder's AI service): SQL Workshop → AI writes SQL from a question (shown in an editor, never run automatically), explains a query or an error, and describes tables and columns for LLMs (notes, optionally `COMMENT ON`, with AI drafts from names, types and keys only); **Create pages with AI** turns a description into proposed pages that the developer edits and confirms ([chapter 3](guide/03-builder.md)). The model never sees table rows |
52
53
  | Sample data source for development (26.1) | ✅ | SQL Workshop → **Sample Data** ([chapter 16](guide/16-files.md#sql-workshop--sample-data)): generators proposed per column from the catalog and column names (names, e-mail addresses, phones, companies, addresses, words and sentences, codes, number/date/time ranges, booleans, value lists from enums and CHECKs, sequences, foreign keys picking existing or newly inserted parent rows, values relative to another column, % nulls; identity/serial/generated columns skipped; unique and simple CHECK constraints respected), rows per table, a seed for repeatable data, preview (inserted and rolled back), insert in one transaction with parents first, download as SQL INSERTs or CSV, saved generator definitions |
54
+ | App Gallery: sample, starter and custom apps | ✅ | (sprint 61) The **App Gallery** in the builder ([chapter 3](guide/03-builder.md#app-gallery)): *Sample Apps* shipped with pgkiln (HR Demo, Tasks) installed by administrators; *Starter Apps* (Team Tasks, Contacts, Expense Claims, Asset Inventory, Event Registrations) shipped as blueprints, created after their review in the current workspace with a role and schema of their own; *Custom Apps*: the workspace's boilerplates. **Missing:** a gallery fed from a remote catalogue |
55
+ | Application groups | ✅ | (sprint 61) Workspace utilities → **Application groups**: a workspace's named groups, a group per application, a group filter and labels on the App Builder home ([chapter 3](guide/03-builder.md#application-groups)) |
56
+ | Cross application reports | ✅ | (sprint 61) In Workspace utilities' side column, over every application of the workspace: application attributes, build options, developer comments, authentication, authorization schemes, password items and theme summary |
53
57
 
54
58
  ## Regions
55
59
 
@@ -179,7 +183,7 @@ available dropped without anything being removed.)
179
183
 
180
184
  | APEX | pgkiln | Notes |
181
185
  |---|---|---|
182
- | SQL Workshop: SQL commands, object browser | ✅ | The object browser shows columns, RLS policies, grants, data and function source |
186
+ | SQL Workshop: SQL commands, object browser | ✅ | (sprint 61) A **home page** like APEX's: tiles, recently created tables, your recent SQL commands and the workspace's recent scripts, and the session's **default schema** (first in the search path of SQL Commands and Scripts). The object browser shows columns, RLS policies, grants, data and function source |
183
187
  | RESTful services (ORDS) | ✅ | [PostgREST](https://postgrest.org) next to pgkiln: `api` schema, the same RLS as the UI, per-app API role, tokens in the builder, a pre-request check, and **OAuth clients** (client credentials, like ORDS `oauth.create_client`) so tokens renew themselves |
184
188
  | REST handler editor, REST-enabled SQL | ✅ | **REST modules** in the builder: handlers (method, path with parameters, SQL as collection, item or statements, roles, public) served by pgkiln with bearer tokens and an OpenAPI description; plus PostgREST for schema-wide APIs. **Missing:** REST-enabled SQL (rarely desirable) |
185
189
  | SQL scripts, query builder, Quick SQL | ✅ | **SQL Scripts**: saved, upload/download, a result per statement, stop or continue on errors, optionally one transaction, run history. **Quick SQL** (a subset: tables, child tables, types, the main column directives, `/auditcols`, settings, views). A graphical **query builder**: tables as boxes on a canvas (dragged, placed where left), joins along foreign keys or drawn from column to column (inner or left), column functions with automatic `group by`, conditions, sort, open in SQL Commands; without JavaScript the same as forms ([chapter 3](guide/03-builder.md#sql-workshop)) |
@@ -209,7 +213,8 @@ available dropped without anything being removed.)
209
213
 
210
214
  | APEX | pgkiln | Notes |
211
215
  |---|---|---|
212
- | Developer accounts | ✅ | |
216
+ | Developer accounts, workspace sign-in | ✅ | (sprint 61) The builder's sign-in page like APEX's: workspace (optional; it becomes the current one, a wrong one answers like a wrong password), username, password with a Show button, *Remember workspace and username*, a link to Administration |
217
+ | Workspace message, environment banner, workspace utilization (Manage Service) | ✅ | (sprint 61) An **Administration** menu in the icon rail; administrators and workspace administrators set a **workspace message** (on the App Builder home) and an **environment banner** (a coloured label on every builder page of the workspace), and see **workspace utilization** (applications, pages, page views, users, static files, schema storage) ([chapter 3](guide/03-builder.md#workspace-message-and-environment-banner)). **Missing:** extension links, workspace-level preferences such as disabling the SQL Workshop |
213
218
  | Instance administration, install/upgrade logs (26.1) | ✅ | Versioned migrations (`npm run db:migrate`), every run logged; Workspace utilities → **Installation** (administrators): server version, install and upgrade runs with errors, applied migrations, and warnings for migrations the database misses or the server doesn't know ([chapter 3](guide/03-builder.md)). Workspace utilities → **Instance settings**: session length and sign-in throttling (stored in the database, over the environment variables) and an overview of the server's configuration without secrets; a server whose database lacks migrations says so (503) or applies them (`MIGRATE_ON_START`). Other settings stay environment variables |
214
219
  | Debug messages | ✅ | Debug levels 1–9 per app; `meta.debug(level, text)` and `meta.debug_enabled(level)` from application SQL (APEX_DEBUG); timed entries per request (page steps, regions, processes, branches, errors, SQL notices); Activity → **Debug messages** viewer per page view with filters and the slowest step highlighted; retention 1–90 days; password item values are never recorded ([chapter 6](guide/06-processing.md)). (sprint 50) Debug for **one session** from the developer toolbar, the application staying out of debug. **Missing:** debug entries for background jobs and REST requests |
215
220
  | Developer toolbar, session state viewer | ✅ | (sprint 50) Developers signed in to the builder see a toolbar on the pages of their applications in the same browser: App Builder, the application, **Edit page** (Page Designer), **Session** (the session state viewer: user, roles, session, language, time zone, debug level, this page's items, application items and other pages' items; passwords never shown; clear the page's items) **Quick edit** (sprint 59: click a region, item or button to open it in the Page Designer) and **Debug** for this session only. A separate random token (cookie path `/a`, HttpOnly) of a live builder session of a developer of the application's workspace ([chapter 3](guide/03-builder.md#developer-toolbar)). **Missing:** Theme Roller from the page |
@@ -6,7 +6,16 @@ The builder lives at `/builder`. Everything it does is also possible in SQL (see
6
6
  ## Signing in and developer accounts
7
7
 
8
8
  Sign in with a developer account. The first one is `admin` / `admin`, and a red banner reminds you
9
- to change it. On the **Developers** page you can:
9
+ to change it.
10
+
11
+ The sign-in page (`/builder/login`) is laid out like APEX's: **Workspace** (optional), **Username** and
12
+ **Password** (with a *Show* button). A workspace you name must be one of yours (administrators: any); it becomes the
13
+ current one, and a wrong one gets the same answer as a wrong password. Left empty, you continue in your first
14
+ workspace and switch in your account menu. **Remember workspace and username** keeps both on this device (an
15
+ HttpOnly cookie for `/builder`, no password); signing in without the tick forgets them. *Administration* under the
16
+ form signs in and opens Workspace utilities.
17
+
18
+ On the **Developers** page you can:
10
19
 
11
20
  - change your own password (minimum 8 characters; other builder sessions of yours end);
12
21
  - as an **administrator**: add developer accounts (developers or administrators), make a developer
@@ -33,6 +42,13 @@ department. Every installation has the **Default** workspace, which holds the ap
33
42
  - **New applications** (Create, from a file, pasted data, existing tables, a blueprint) and **imports** go into the
34
43
  current workspace; a working copy stays in its main application's workspace. Imports made with the command line
35
44
  (`pgkiln import`) go into Default. Exports don't carry the workspace.
45
+ - **Workspace utilities**: tiles for users and sign-in, application groups, the App Gallery, developers, the SQL
46
+ Workshop and the dashboard (and, for administrators, instance settings, workspaces, AI and mail services and the
47
+ installation), with **Cross Application Reports** in the side column (APEX: Cross Application Reports), each over
48
+ every application of the current workspace: *Application attributes* (type, sign-in, availability, build status,
49
+ debug level, language, database role), *Build options*, *Developer comments*, *Authentication* (sign-in methods,
50
+ identity providers, LDAP, access, the login page, Forgot password), *Authorization schemes*, *Password items* and
51
+ *Theme summary*.
36
52
  - Workspace utilities → **Workspaces** (administrators): add a workspace (you become its first developer), rename it,
37
53
  choose its developers, move applications to another workspace and delete an empty workspace.
38
54
  - **Workspace administrators**: on a workspace's page, administrators tick which of its developers administer it. A
@@ -45,6 +61,21 @@ runs as pgkiln's owner, and its application code (processes, regions, validation
45
61
  connection, from which SQL can reach other shared applications' data and metadata. Make a workspace **isolated** when
46
62
  its developers must not reach other teams' applications or data.
47
63
 
64
+ ### Workspace message and environment banner
65
+
66
+ Administrators and the workspace's administrators set them on the workspace's page (*Manage service*, or the
67
+ Administration menu → *Workspace message and environment banner*; APEX: Define Workspace Message, Define Environment
68
+ Banner): a **message** (plain text, up to 2000 characters) shown to the workspace's developers on the App Builder home,
69
+ and an **environment banner**: a label of up to 40 characters in one of eight colours, shown at the top of every
70
+ builder page while the workspace is current.
71
+
72
+ ### Workspace utilization
73
+
74
+ Administration menu → **Workspace utilization** (`/builder/workspaces/<id>/utilization`; APEX: Workspace
75
+ Utilization), for administrators and the workspace's administrators: the number of applications, pages, developers,
76
+ page views of the last 30 days and SQL scripts; per application its pages, regions, items, page views, users and the
77
+ size of its static files; and the schemas the workspace's database roles use with their tables and storage.
78
+
48
79
  ### Isolated workspaces
49
80
 
50
81
  On a workspace's page an administrator chooses **Isolate this workspace** (Workspace utilities → Workspaces → the
@@ -89,8 +120,11 @@ longer sign in. Delete a workspace only when it is shared and empty; its logins
89
120
 
90
121
  Every builder page has the same frame, modelled on an IDE:
91
122
 
92
- - **The icon rail** on the left: App Builder, SQL Workshop, Users, Developers, **Search** (on the
93
- pages of an application), Help, and your account menu (the circle with your initials) with the
123
+ - **The icon rail** on the left: App Builder, SQL Workshop, [App Gallery](#app-gallery), **Search** (on the
124
+ pages of an application); at the bottom the **Administration** menu (Workspace utilities; for administrators of the
125
+ current workspace *Manage service*: [workspace message and environment banner](#workspace-message-and-environment-banner),
126
+ [workspace utilization](#workspace-utilization) and the workspace's page; Manage users and groups, Developers,
127
+ Monitor activity, Change my password), Help, and your account menu (the circle with your initials) with the
94
128
  **builder theme** (*Dark*, the default; *Light*; or *System*, which follows the operating system),
95
129
  Change password and Sign out. The theme is remembered on this device, also after signing out;
96
130
  it only changes the builder, not your applications.
@@ -101,6 +135,8 @@ Every builder page has the same frame, modelled on an IDE:
101
135
 
102
136
  - **The status bar** at the bottom: who is signed in, the current [workspace](#workspaces), the database, the
103
137
  builder's language and the pgkiln version.
138
+ - **An environment banner** (when the current workspace has one) across the top: a coloured band with a label such as
139
+ DEVELOPMENT or TEST, so nobody mistakes one environment for another.
104
140
 
105
141
  On phones the rail gets narrower and the breadcrumb shows only the current page.
106
142
 
@@ -120,6 +156,34 @@ The home page is laid out like APEX's App Builder:
120
156
  **Actions**, to sort. The view and the sort are remembered until you sign out.
121
157
  - **A side column** (on the right on wide screens, below the list otherwise): About, **Recent** (the
122
158
  applications you opened last) and Tasks.
159
+ - **The workspace message**, when the workspace has one, above the tiles.
160
+ - **Application groups**: when the workspace has [groups](#application-groups), a select next to the views shows one
161
+ group; each application shows its group.
162
+
163
+ ### Application groups
164
+
165
+ Workspace utilities → **Application groups** (`/builder/app-groups`; APEX: Application Groups) organises the
166
+ applications of the current workspace into named groups: add, rename and delete groups, and choose each
167
+ application's group. The App Builder home then filters by group. Groups belong to the workspace, not to the
168
+ applications: they are not exported, an in-place import keeps them, and an application moved to another workspace
169
+ leaves its group. Every developer of the workspace manages them.
170
+
171
+ ## App Gallery
172
+
173
+ The **App Gallery** (the cube in the icon rail, `/builder/gallery`; APEX: App Gallery) has three tabs:
174
+
175
+ - **Sample Apps**: applications shipped with pgkiln (HR Demo, Tasks) with their own schema, data and **demo accounts
176
+ with known passwords**, so install them on a development or demo instance only. Administrators install them (the
177
+ same scripts as `pgkiln migrate --example hr`); they go into the current workspace. An installed one shows Run and
178
+ Edit.
179
+ - **Starter Apps**: small applications (Team Tasks, Contacts, Expense Claims, Asset Inventory, Event Registrations)
180
+ shipped as [blueprints](#creating-an-application-from-a-blueprint). **Install** opens the blueprint's review:
181
+ nothing is created before you confirm, the application gets a new role and schema in the current workspace, and you
182
+ may edit the blueprint first (another alias, more columns). Any developer installs them.
183
+ - **Custom Apps**: the workspace's boilerplate applications (Application type *Boilerplate*): *Create from it* opens
184
+ Create with that boilerplate chosen.
185
+
186
+ The list is `examples/gallery/gallery.json`; add your own starters there as blueprint files.
123
187
 
124
188
  ### Creating an application
125
189
 
@@ -950,14 +1014,21 @@ may use), a form to **issue a token** for an account, and `curl` examples. See
950
1014
 
951
1015
  ## SQL Workshop
952
1016
 
953
- - **SQL Commands**: run any SQL as the **owner connection**, not as an application role. Multiple
1017
+ The SQL Workshop opens on its **home** (`/builder/sql`; APEX: the SQL Workshop home): tiles for the Object Browser,
1018
+ SQL Commands, SQL Scripts, the utilities and Quick SQL; **Recently created tables** (the newest tables you can read:
1019
+ PostgreSQL keeps no creation time, so object ids decide), your **recent SQL commands** (click one to open it in SQL
1020
+ Commands; other developers' are never shown) and the workspace's **recent SQL scripts**. The side column sets the
1021
+ session's **schema** (APEX: the default schema): it goes first in the search path of SQL Commands and SQL Scripts until
1022
+ you sign out. Tasks link to Quick SQL, blueprints, table descriptions, sample data and Generate DDL.
1023
+
1024
+ - **SQL Commands** (`/builder/sql/commands`): run any SQL as the **owner connection**, not as an application role. Multiple
954
1025
  statements are allowed; the result of the last one is shown (up to 500 rows). Press
955
1026
  **Ctrl/Cmd + Enter** to run. The [code editor](#the-code-editor) suggests every schema, table,
956
1027
  column and function the owner sees.
957
1028
  - **Object Browser**: tables, views and functions per schema. For a table you see columns, types
958
1029
  and defaults, **row level security policies**, **grants** and the first 25 rows; for a
959
1030
  function, its source.
960
- - **SQL Scripts**: saved scripts, shared by all developers. Create one in the editor, upload a
1031
+ - **SQL Scripts**: saved scripts, shared by the developers of the workspace. Create one in the editor, upload a
961
1032
  `.sql` file (UTF-8, up to 5 MB) or save one from Quick SQL; download it again as `.sql`. **Run**
962
1033
  splits the script into statements at semicolons (outside strings, comments, quoted identifiers,
963
1034
  `$$` bodies and `BEGIN ATOMIC … END`) and runs them one after another, with a **result per
@@ -233,6 +233,10 @@ src/
233
233
  templates.ts template components: preview, plug-in export/import, region settings, report column templates
234
234
  code-editor.ts code fields (data-code marks), /builder/code/completions (scoped to the app's role), /builder/code/check
235
235
  instance.ts Workspace utilities → Instance settings (src/instance.ts: session and sign-in settings, configuration overview)
236
+ gallery.ts the App Gallery (sprint 61): examples/gallery/gallery.json, sample apps (administrators, migrate --example),
237
+ starter apps (blueprints → openBlueprint's review), custom apps (the workspace's boilerplates)
238
+ app-groups.ts application groups (092): a workspace's groups, a group per application (the App Builder home filters)
239
+ cross-app.ts Cross Application Reports (sprint 61): REPORTS (one SQL per topic over the workspace's applications)
236
240
  workspaces.ts workspaces (064): loadWorkspaces/appAllowed (checked in ui.ts developer() for every /apps/:id and /pages/:pid
237
241
  request), the current workspace (session state __WS), placeApp, the switcher, Workspace utilities → Workspaces;
238
242
  (090) isolation and the workspace's database roles, workshopDb (the SQL Workshop's connection)
@@ -293,6 +297,8 @@ test/
293
297
  page-wizards.test.ts create page wizards: catalog defaults, every page type generated and rendered, refusals, the builder steps
294
298
  theme-styles.test.ts Theme Roller style variants (checks, CSS, user choice per app, builder page), template options, base style Iris
295
299
  workspaces.test.ts workspaces (064): Default, administrators' pages, current workspace, refused apps, imports and copies
300
+ gallery.test.ts the App Gallery: every starter created from its review with all its pages rendering; sample apps (admins)
301
+ builder-apex-screens.test.ts sprint 61: sign-in with a workspace, message and banner, utilization, SQL Workshop home, groups, reports
296
302
  workspace-isolation.test.ts isolated workspaces (090): logins, RLS on meta, app_id, roles, SQL Workshop, scripts, imports
297
303
  ai.test.ts AI services: Generate text with AI (text, structured outputs, errors, limits, keys), its dynamic action,
298
304
  meta.ai_generate, the providers, HR page 37; against ai-mock.ts (no real API calls)
@@ -0,0 +1,13 @@
1
+ # App Gallery
2
+
3
+ The builder's **App Gallery** (`/builder/gallery`) lists what `gallery.json` names:
4
+
5
+ - `samples`: applications shipped with pgkiln, installed by an administrator: `example` names a directory of
6
+ `examples/` (installed like `pgkiln migrate --example <name>`), `file` a single SQL file in `examples/`.
7
+ `alias` is the application they create (an installed one shows Run and Edit).
8
+ - `starters`: [blueprints](../../docs/guide/03-builder.md#creating-an-application-from-a-blueprint) in `starters/`.
9
+ Install opens the blueprint's review; the developer creates the application from it.
10
+
11
+ Add a starter by writing a blueprint file in `starters/` and an entry in `gallery.json` (a key of lower-case
12
+ letters, digits and `-`, a title, an [icon name](../../docs/guide/09-reference.md#icons) and a description).
13
+ `test/gallery.test.ts` creates every starter and opens all its pages.
@@ -0,0 +1,20 @@
1
+ {
2
+ "samples": [
3
+ {"key": "hr", "title": "HR Demo", "alias": "hr", "icon": "briefcase", "example": "hr",
4
+ "description": "The showcase of pgkiln on the classic EMP and DEPT tables: reports and forms, an interactive grid, charts, maps, a calendar, faceted search, approvals and workflows, documents, a REST API, translations and a Progressive Web App. Demo accounts king, blake, jones, allen, scott and demo, with the username as password."},
5
+ {"key": "tasks", "title": "Tasks", "alias": "tasks", "icon": "check", "file": "tasks-app.sql",
6
+ "description": "The tutorial application: a personal task list where every user sees only their own tasks (row level security), with a business rule in PL/pgSQL behind a button. Demo accounts ann and bob (password ann-password, bob-password)."}
7
+ ],
8
+ "starters": [
9
+ {"key": "team-tasks", "title": "Team Tasks", "icon": "layout-grid", "file": "starters/team-tasks.json",
10
+ "description": "Projects and their tasks with status, priority, assignee and due date: reports and forms, a faceted search, a calendar of due dates and a dashboard."},
11
+ {"key": "contacts", "title": "Contacts", "icon": "contact", "file": "starters/contacts.json",
12
+ "description": "Companies, their contacts and the interactions with them: contact cards, a faceted search, reports and forms and a dashboard."},
13
+ {"key": "expense-claims", "title": "Expense Claims", "icon": "receipt", "file": "starters/expense-claims.json",
14
+ "description": "Claims with their expenses in a master-detail page, an editable grid, a chart by category and a dashboard."},
15
+ {"key": "asset-inventory", "title": "Asset Inventory", "icon": "package", "file": "starters/asset-inventory.json",
16
+ "description": "Assets with their tags, locations, owners and purchase data: a faceted search, an editable grid of locations, a chart by category and a dashboard."},
17
+ {"key": "event-registrations", "title": "Event Registrations", "icon": "calendar-days", "file": "starters/event-registrations.json",
18
+ "description": "Events in a calendar and the people who registered for them, with reports, forms and a dashboard."}
19
+ ]
20
+ }
@@ -0,0 +1,30 @@
1
+ {"blueprint": 1, "name": "Asset Inventory", "alias": "asset-inventory", "schema": "asset_inventory",
2
+ "tables": [
3
+ {"name": "location", "label": "Locations", "columns": [
4
+ {"name": "name", "type": "text", "required": true, "unique": true},
5
+ {"name": "building", "type": "text"},
6
+ {"name": "floor", "type": "integer"}]},
7
+ {"name": "asset", "label": "Assets", "columns": [
8
+ {"name": "location_id", "references": "location"},
9
+ {"name": "tag", "type": "text", "required": true, "unique": true},
10
+ {"name": "name", "type": "text", "required": true},
11
+ {"name": "category", "type": "text", "required": true, "values": ["Laptop", "Monitor", "Phone", "Furniture", "Vehicle", "Other"]},
12
+ {"name": "assigned_to", "type": "text"},
13
+ {"name": "purchased_on", "type": "date"},
14
+ {"name": "price", "type": "number"},
15
+ {"name": "in_use", "type": "boolean"}]}],
16
+ "pages": [
17
+ {"type": "report_form", "table": "asset", "page": 2, "form_page": 3, "label": "Assets", "icon": "list"},
18
+ {"type": "facets", "table": "asset", "page": 4, "label": "Find assets", "icon": "filter"},
19
+ {"type": "grid", "table": "location", "page": 5, "label": "Locations", "icon": "map"},
20
+ {"type": "chart", "table": "asset", "page": 6, "label": "By category", "icon": "chart"}],
21
+ "dashboard": true,
22
+ "sample_data": [
23
+ {"table": "location", "columns": ["id", "name", "building", "floor"], "rows": [
24
+ [1, "Head office 2nd floor", "Main", 2], [2, "Head office 3rd floor", "Main", 3], [3, "Warehouse", "North", 0]]},
25
+ {"table": "asset", "columns": ["location_id", "tag", "name", "category", "assigned_to", "purchased_on", "price", "in_use"], "rows": [
26
+ [1, "A-0001", "ThinkPad T14", "Laptop", "Ann", "2025-03-10", 1249.00, true],
27
+ [1, "A-0002", "Dell 27\" monitor", "Monitor", "Ann", "2025-03-10", 329.00, true],
28
+ [2, "A-0003", "MacBook Air", "Laptop", "Ben", "2024-11-02", 1399.00, true],
29
+ [2, "A-0004", "Standing desk", "Furniture", null, "2023-06-15", 610.00, false],
30
+ [3, "A-0005", "Delivery van", "Vehicle", "Logistics", "2022-01-20", 32500.00, true]]}]}
@@ -0,0 +1,41 @@
1
+ {"blueprint": 1, "name": "Contacts", "alias": "contacts", "schema": "contacts",
2
+ "tables": [
3
+ {"name": "company", "label": "Companies", "columns": [
4
+ {"name": "name", "type": "text", "required": true, "unique": true},
5
+ {"name": "industry", "type": "text", "values": ["Retail", "Manufacturing", "Services", "Public sector", "Technology"]},
6
+ {"name": "city", "type": "text"},
7
+ {"name": "website", "type": "text"}]},
8
+ {"name": "contact", "label": "Contacts", "columns": [
9
+ {"name": "company_id", "references": "company"},
10
+ {"name": "first_name", "type": "text", "required": true},
11
+ {"name": "last_name", "type": "text", "required": true},
12
+ {"name": "email", "type": "text", "unique": true},
13
+ {"name": "phone", "type": "text"},
14
+ {"name": "role", "type": "text"},
15
+ {"name": "status", "type": "text", "required": true, "values": ["Lead", "Customer", "Former customer"]}]},
16
+ {"name": "interaction", "label": "Interactions", "columns": [
17
+ {"name": "contact_id", "references": "contact", "required": true},
18
+ {"name": "happened_on", "type": "date", "required": true},
19
+ {"name": "kind", "type": "text", "required": true, "values": ["Call", "Meeting", "E-mail", "Visit"]},
20
+ {"name": "notes", "type": "text"}]}],
21
+ "pages": [
22
+ {"type": "report_form", "table": "company", "page": 2, "form_page": 3, "label": "Companies", "icon": "building"},
23
+ {"type": "cards", "table": "contact", "page": 4, "label": "Contacts", "icon": "users"},
24
+ {"type": "report_form", "table": "contact", "page": 5, "form_page": 6, "label": "Contact list", "icon": "list"},
25
+ {"type": "facets", "table": "contact", "page": 7, "label": "Find contacts", "icon": "filter"},
26
+ {"type": "report_form", "table": "interaction", "page": 8, "form_page": 9, "label": "Interactions", "icon": "activity"}],
27
+ "dashboard": true,
28
+ "sample_data": [
29
+ {"table": "company", "columns": ["id", "name", "industry", "city", "website"], "rows": [
30
+ [1, "Northwind Traders", "Retail", "Utrecht", "https://northwind.example"],
31
+ [2, "Contoso Machines", "Manufacturing", "Eindhoven", "https://contoso.example"],
32
+ [3, "Fabrikam Services", "Services", "Rotterdam", null]]},
33
+ {"table": "contact", "columns": ["id", "company_id", "first_name", "last_name", "email", "phone", "role", "status"], "rows": [
34
+ [1, 1, "Anna", "de Vries", "anna@northwind.example", "+31 30 123 4567", "Buyer", "Customer"],
35
+ [2, 1, "Bram", "Jansen", "bram@northwind.example", null, "Director", "Customer"],
36
+ [3, 2, "Chloe", "Bakker", "chloe@contoso.example", "+31 40 765 4321", "Engineer", "Lead"],
37
+ [4, 3, "Daan", "Visser", "daan@fabrikam.example", null, "Owner", "Former customer"]]},
38
+ {"table": "interaction", "columns": ["contact_id", "happened_on", "kind", "notes"], "rows": [
39
+ [1, "2026-09-12", "Meeting", "Yearly review; wants a quote for spring."],
40
+ [1, "2026-10-02", "E-mail", "Sent the quote."],
41
+ [3, "2026-10-05", "Call", "Interested in a demo."]]}]}
@@ -0,0 +1,29 @@
1
+ {"blueprint": 1, "name": "Event Registrations", "alias": "event-registrations", "schema": "event_registrations",
2
+ "authentication": "app_users",
3
+ "tables": [
4
+ {"name": "event", "label": "Events", "columns": [
5
+ {"name": "title", "type": "text", "required": true},
6
+ {"name": "starts_at", "type": "timestamp", "required": true},
7
+ {"name": "venue", "type": "text"},
8
+ {"name": "capacity", "type": "integer"},
9
+ {"name": "status", "type": "text", "required": true, "values": ["Draft", "Open", "Full", "Closed"]}]},
10
+ {"name": "registration", "label": "Registrations", "columns": [
11
+ {"name": "event_id", "references": "event", "required": true},
12
+ {"name": "attendee", "type": "text", "required": true},
13
+ {"name": "email", "type": "text", "required": true},
14
+ {"name": "registered_on", "type": "date", "required": true},
15
+ {"name": "attended", "type": "boolean"}]}],
16
+ "pages": [
17
+ {"type": "calendar", "table": "event", "page": 2, "label": "Calendar", "icon": "calendar"},
18
+ {"type": "report_form", "table": "event", "page": 3, "form_page": 4, "label": "Events", "icon": "list"},
19
+ {"type": "report_form", "table": "registration", "page": 5, "form_page": 6, "label": "Registrations", "icon": "users"}],
20
+ "dashboard": true,
21
+ "sample_data": [
22
+ {"table": "event", "columns": ["id", "title", "starts_at", "venue", "capacity", "status"], "rows": [
23
+ [1, "PostgreSQL meetup", "2026-11-12 18:30", "Utrecht", 60, "Open"],
24
+ [2, "Low-code workshop", "2026-11-26 09:30", "Amsterdam", 20, "Full"],
25
+ [3, "Year-end drinks", "2026-12-18 17:00", "Head office", 120, "Draft"]]},
26
+ {"table": "registration", "columns": ["event_id", "attendee", "email", "registered_on", "attended"], "rows": [
27
+ [1, "Anna de Vries", "anna@example.com", "2026-10-01", null],
28
+ [1, "Bram Jansen", "bram@example.com", "2026-10-03", null],
29
+ [2, "Chloe Bakker", "chloe@example.com", "2026-09-28", null]]}]}
@@ -0,0 +1,32 @@
1
+ {"blueprint": 1, "name": "Expense Claims", "alias": "expense-claims", "schema": "expense_claims",
2
+ "tables": [
3
+ {"name": "claim", "label": "Claims", "columns": [
4
+ {"name": "employee", "type": "text", "required": true},
5
+ {"name": "purpose", "type": "text", "required": true},
6
+ {"name": "submitted_on", "type": "date", "required": true},
7
+ {"name": "status", "type": "text", "required": true, "values": ["Draft", "Submitted", "Approved", "Rejected", "Paid"]},
8
+ {"name": "approver", "type": "text"}]},
9
+ {"name": "expense", "label": "Expenses", "columns": [
10
+ {"name": "claim_id", "references": "claim", "required": true},
11
+ {"name": "spent_on", "type": "date", "required": true},
12
+ {"name": "category", "type": "text", "required": true, "values": ["Travel", "Lodging", "Meals", "Supplies", "Other"]},
13
+ {"name": "description", "type": "text"},
14
+ {"name": "amount", "type": "number", "required": true}]}],
15
+ "pages": [
16
+ {"type": "master_detail", "table": "claim", "page": 2, "label": "Claims", "icon": "file"},
17
+ {"type": "report_form", "table": "expense", "page": 3, "form_page": 4, "label": "Expenses", "icon": "list"},
18
+ {"type": "chart", "table": "expense", "page": 5, "label": "By category", "icon": "chart"},
19
+ {"type": "grid", "table": "claim", "page": 6, "label": "Edit claims", "icon": "grid"}],
20
+ "dashboard": true,
21
+ "sample_data": [
22
+ {"table": "claim", "columns": ["id", "employee", "purpose", "submitted_on", "status", "approver"], "rows": [
23
+ [1, "Ann", "Customer visit Hamburg", "2026-09-30", "Approved", "Ben"],
24
+ [2, "Cleo", "Conference in Lisbon", "2026-10-06", "Submitted", null],
25
+ [3, "Dana", "Office supplies", "2026-10-08", "Draft", null]]},
26
+ {"table": "expense", "columns": ["claim_id", "spent_on", "category", "description", "amount"], "rows": [
27
+ [1, "2026-09-24", "Travel", "Train Utrecht-Hamburg return", 189.40],
28
+ [1, "2026-09-24", "Lodging", "Hotel, one night", 132.00],
29
+ [1, "2026-09-25", "Meals", "Lunch with the customer", 64.50],
30
+ [2, "2026-10-01", "Travel", "Flight", 245.00],
31
+ [2, "2026-10-01", "Lodging", "Hotel, three nights", 420.00],
32
+ [3, "2026-10-07", "Supplies", "Notebooks and pens", 38.95]]}]}
@@ -0,0 +1,35 @@
1
+ {"blueprint": 1, "name": "Team Tasks", "alias": "team-tasks", "schema": "team_tasks",
2
+ "tables": [
3
+ {"name": "project", "label": "Projects", "columns": [
4
+ {"name": "name", "type": "text", "required": true, "unique": true},
5
+ {"name": "owner", "type": "text"},
6
+ {"name": "status", "type": "text", "required": true, "values": ["Planned", "Active", "On hold", "Done"]},
7
+ {"name": "start_date", "type": "date"},
8
+ {"name": "end_date", "type": "date"}]},
9
+ {"name": "task", "label": "Tasks", "columns": [
10
+ {"name": "project_id", "references": "project", "required": true},
11
+ {"name": "title", "type": "text", "required": true},
12
+ {"name": "assignee", "type": "text"},
13
+ {"name": "status", "type": "text", "required": true, "values": ["To do", "In progress", "Blocked", "Done"]},
14
+ {"name": "priority", "type": "text", "values": ["Low", "Normal", "High"]},
15
+ {"name": "due", "type": "date"},
16
+ {"name": "hours", "type": "number"}]}],
17
+ "pages": [
18
+ {"type": "report_form", "table": "project", "page": 2, "form_page": 3, "label": "Projects", "icon": "layers"},
19
+ {"type": "report_form", "table": "task", "page": 4, "form_page": 5, "label": "Tasks", "icon": "check"},
20
+ {"type": "facets", "table": "task", "page": 6, "label": "Find tasks", "icon": "filter"},
21
+ {"type": "calendar", "table": "task", "page": 7, "label": "Due dates", "icon": "calendar"}],
22
+ "dashboard": true,
23
+ "sample_data": [
24
+ {"table": "project", "columns": ["id", "name", "owner", "status", "start_date", "end_date"], "rows": [
25
+ [1, "Website relaunch", "Ann", "Active", "2026-09-01", "2026-12-15"],
26
+ [2, "Customer portal", "Ben", "Planned", "2026-11-01", "2027-03-31"],
27
+ [3, "Office move", "Cleo", "Done", "2026-05-01", "2026-08-30"]]},
28
+ {"table": "task", "columns": ["project_id", "title", "assignee", "status", "priority", "due", "hours"], "rows": [
29
+ [1, "Design the home page", "Dana", "Done", "High", "2026-09-20", 16],
30
+ [1, "Write the copy", "Eli", "In progress", "Normal", "2026-10-25", 12],
31
+ [1, "Move the content", "Dana", "To do", "Normal", "2026-11-15", 24],
32
+ [1, "Test on phones", "Finn", "To do", "High", "2026-12-01", 8],
33
+ [2, "Gather requirements", "Ben", "In progress", "High", "2026-11-10", 20],
34
+ [2, "Choose the sign-in", "Gus", "Blocked", "Normal", "2026-11-20", 4],
35
+ [3, "Pack the archive", "Cleo", "Done", "Low", "2026-08-10", 10]]}]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pgkiln",
3
- "version": "0.37.0",
3
+ "version": "0.38.0",
4
4
  "description": "Open source low-code, SQL-driven application builder for PostgreSQL, inspired by Oracle APEX",
5
5
  "keywords": [
6
6
  "postgresql",