Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,20 @@ as you fix it, and `Esc` abandons the edit. Here a `TIME(15)` column rejects `08

---

### `LOOKUP` columns — pick a value instead of typing it

A column declared `LOOKUP <table>.<column> DISPLAY <column>` edits through a dropdown in
both BROWSE and forms — showing the friendlier label, storing the code. Here `SCHEDID`
is constrained to `SCHEDULES.SCHEDID`, displaying `DESCR`.

![BROWSE editing a LOOKUP column via dropdown](docs/screenshots/screenshot-lookup-browse.png)

A field-bound `@ SAY GET` (one whose name matches a table column) renders the same picker:

![A form field bound to a LOOKUP column](docs/screenshots/screenshot-lookup-form.png)

---

### Aggregate commands & dBASE III parity

`SUM`, `AVERAGE`, `? ROUND(…)`, `? MAX(…)`, and `SORT ON … TO` — numeric aggregates and sorted copies, honouring the active filter.
Expand Down
Binary file modified docs/screenshots/screenshot-assistant-wizard.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-assistant.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-csv.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-index.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-list.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/screenshots/screenshot-lookup-browse.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/screenshots/screenshot-lookup-form.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-modify-structure.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-parity.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-repl-session.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/screenshots/screenshot-terminal.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
49 changes: 49 additions & 0 deletions scripts/capture-screenshots.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -295,5 +295,54 @@ console.log('14. NEW: BROWSE per-cell validation rejecting a TIME(15) edit');
await page.close();
}

// ── 15. screenshot-lookup-browse.png (NEW in v1.3.0) ──────────────────────
console.log('15. NEW: BROWSE editing a LOOKUP column via dropdown');
{
const page = await newPage();
await boot(page);
await cmd(page, 'USE DATABASE screenshotdb', 800);
await cmd(page, 'DROP TABLE schedules', 400);
await cmd(page, 'DROP TABLE staff', 400);
await cmd(page, 'CREATE TABLE schedules (SCHEDID CHAR(4), DESCR CHAR(30))', 700);
await cmd(page, 'USE schedules', 500);
await cmd(page, 'APPEND RECORD', 400);
await cmd(page, 'REPLACE SCHEDID WITH "S001", DESCR WITH "Standard 40h (08:00-16:30)"', 600);
await cmd(page, 'APPEND RECORD', 400);
await cmd(page, 'REPLACE SCHEDID WITH "S002", DESCR WITH "Short 31.25h (09:00-16:00)"', 600);
await cmd(page, 'CREATE TABLE staff (NAME CHAR(30), SCHEDID CHAR(4) LOOKUP SCHEDULES.SCHEDID DISPLAY DESCR)', 700);
await cmd(page, 'USE staff', 500);
await cmd(page, 'APPEND RECORD', 500);
await cmd(page, 'REPLACE NAME WITH "Ada Lovelace", SCHEDID WITH "S001"', 500);
await cmd(page, 'BROWSE', 1200);
await page.waitForSelector('#grid-view:not(.hidden)', { timeout: 8000 });

const td = page.locator('#grid-tbody td[data-ri="0"][data-ci="1"]');
await td.dblclick();
await page.waitForSelector('#grid-tbody select.cell-ed', { timeout: 5000 });
await page.waitForTimeout(300);
await snap(page, 'screenshot-lookup-browse.png');
await page.keyboard.press('Escape');
await page.keyboard.press('Escape');
await page.close();
}

// ── 16. screenshot-lookup-form.png (NEW in v1.3.0) ────────────────────────
console.log('16. NEW: field-bound GET rendering a LOOKUP picker in a form');
{
const page = await newPage();
await boot(page);
await cmd(page, 'USE DATABASE screenshotdb', 800);
await cmd(page, 'USE staff', 500);
await cmd(page, '@ 2, 5 SAY "Name : " GET NAME', 300);
await cmd(page, '@ 3, 5 SAY "Schedule: " GET SCHEDID', 300);
await cmd(page, 'READ', 900);
await page.waitForSelector('#form-view', { state: 'visible', timeout: 6000 });
await page.waitForSelector('#form-view select.f-get', { timeout: 5000 });
await page.waitForTimeout(400);
await snap(page, 'screenshot-lookup-form.png');
await page.keyboard.press('Escape');
await page.close();
}

await browser.close();
console.log('\nDone. All screenshots written to docs/screenshots/');
Loading