Skip to content

Commit d7f86db

Browse files
xuyushun441-sysos-zhuangclaude
authored
fix(showcase): seed Accounts + task map coordinates; bump objectui pin (#1466)
* fix: add cozy-books-clap changeset for @objectstack/console patch * fix(showcase): seed Accounts + task map coordinates; bump objectui pin - data: Account records omitted the required `status` (no default is applied at seed-insert time), so all 3 accounts were rejected and the Accounts list was empty. Set `status` explicitly and add `hq` coordinates. - data: tasks had no `location`, so the Map view excluded every record ("missing or invalid coordinates"). Give each task real lat/lng so the map renders 10 markers. - Bump .objectui-sha to pick up objectstack-ai/objectui#1435 (location/ geolocation cells render as coordinates instead of "[Object]"). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> --------- Co-authored-by: Jack Zhuang <277994282+os-zhuang@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 16d89fa commit d7f86db

4 files changed

Lines changed: 36 additions & 14 deletions

File tree

.changeset/cozy-books-clap.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@objectstack/console": patch
3+
---
4+
5+
fix

.claude/launch.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,25 @@
1414
"runtimeArgs": ["--filter", "@example/app-todo", "dev", "--", "--port", "3001"],
1515
"port": 3001
1616
},
17+
{
18+
"name": "app-showcase (3001)",
19+
"runtimeExecutable": "pnpm",
20+
"runtimeArgs": ["--filter", "@objectstack/example-showcase", "dev", "--port", "3001"],
21+
"port": 3001,
22+
"autoPort": false
23+
},
1724
{
1825
"name": "docs (next.js)",
1926
"runtimeExecutable": "pnpm",
2027
"runtimeArgs": ["--filter", "@objectstack/docs", "dev", "--", "-p", "3002"],
2128
"port": 3002
29+
},
30+
{
31+
"name": "showcase-console",
32+
"runtimeExecutable": "bash",
33+
"runtimeArgs": ["-lc", "cd /Users/zhuangjianguo/Documents/GitHub/objectui && DEV_PROXY_TARGET=http://localhost:3700 VITE_SERVER_URL=http://localhost:3700 pnpm --filter @object-ui/console exec vite --port 5790 --strictPort"],
34+
"port": 5790,
35+
"autoPort": false
2236
}
2337
]
2438
}

.objectui-sha

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
bcd027e813d4c460bed06d53a3c8c78942e28a51
1+
3442c5547328cb5bbbd7ef8a2e704b0d4f0268f3

examples/app-showcase/src/data/index.ts

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,12 @@ const accounts = defineDataset(Account, {
1818
mode: 'upsert',
1919
externalId: 'name',
2020
records: [
21-
{ name: 'Northwind', industry: 'retail', annual_revenue: 8_000_000, website: 'https://northwind.example' },
22-
{ name: 'Contoso', industry: 'technology', annual_revenue: 25_000_000, website: 'https://contoso.example' },
23-
{ name: 'Fabrikam', industry: 'healthcare', annual_revenue: 12_000_000, website: 'https://fabrikam.example' },
21+
// `status` is required and no default is applied at seed-insert time, so it
22+
// must be set explicitly or the row is rejected (this is why Accounts was
23+
// empty). `hq` also exercises the location field.
24+
{ name: 'Northwind', industry: 'retail', annual_revenue: 8_000_000, website: 'https://northwind.example', status: 'active', hq: { lat: 47.6062, lng: -122.3321 } },
25+
{ name: 'Contoso', industry: 'technology', annual_revenue: 25_000_000, website: 'https://contoso.example', status: 'active', hq: { lat: 37.7749, lng: -122.4194 } },
26+
{ name: 'Fabrikam', industry: 'healthcare', annual_revenue: 12_000_000, website: 'https://fabrikam.example', status: 'prospect', hq: { lat: 40.7128, lng: -74.0060 } },
2427
],
2528
});
2629

@@ -41,16 +44,16 @@ const tasks = defineDataset(Task, {
4144
mode: 'upsert',
4245
externalId: 'title',
4346
records: [
44-
{ title: 'Audit current IA', project: { externalId: 'Website Relaunch' }, assignee: 'ada@example.com', status: 'done', priority: 'medium', estimate_hours: 8, progress: 100, done: true, created_at: cel`daysAgo(20)`, start_date: cel`daysAgo(20)`, end_date: cel`daysAgo(18)`, due_date: cel`daysAgo(18)` },
45-
{ title: 'Design system', project: { externalId: 'Website Relaunch' }, assignee: 'ada@example.com', status: 'in_review', priority: 'high', estimate_hours: 24, progress: 80, done: false, created_at: cel`daysAgo(14)`, start_date: cel`daysAgo(12)`, end_date: cel`daysFromNow(2)`, due_date: cel`daysFromNow(2)` },
46-
{ title: 'Build homepage', project: { externalId: 'Website Relaunch' }, assignee: 'sam@example.com', status: 'in_progress', priority: 'high', estimate_hours: 40, progress: 45, done: false, created_at: cel`daysAgo(8)`, start_date: cel`daysAgo(6)`, end_date: cel`daysFromNow(10)`, due_date: cel`daysFromNow(10)` },
47-
{ title: 'SEO migration plan', project: { externalId: 'Website Relaunch' }, assignee: 'sam@example.com', status: 'todo', priority: 'medium', estimate_hours: 16, progress: 0, done: false, created_at: cel`daysAgo(3)`, start_date: cel`daysFromNow(5)`, end_date: cel`daysFromNow(15)`, due_date: cel`daysFromNow(15)` },
48-
{ title: 'Content backlog', project: { externalId: 'Website Relaunch' }, assignee: 'grace@example.com', status: 'backlog', priority: 'low', estimate_hours: 12, progress: 0, done: false, created_at: cel`daysAgo(2)`, due_date: cel`daysFromNow(30)` },
49-
{ title: 'Ingest pipeline', project: { externalId: 'Data Platform' }, assignee: 'linus@example.com', status: 'in_progress', priority: 'urgent', estimate_hours: 60, progress: 55, done: false, created_at: cel`daysAgo(40)`, start_date: cel`daysAgo(35)`, end_date: cel`daysFromNow(20)`, due_date: cel`daysFromNow(20)` },
50-
{ title: 'Warehouse schema', project: { externalId: 'Data Platform' }, assignee: 'linus@example.com', status: 'in_review', priority: 'high', estimate_hours: 30, progress: 90, done: false, created_at: cel`daysAgo(25)`, start_date: cel`daysAgo(22)`, end_date: cel`daysFromNow(3)`, due_date: cel`daysFromNow(3)` },
51-
{ title: 'PII access review', project: { externalId: 'Compliance Audit' }, assignee: 'grace@example.com', status: 'todo', priority: 'urgent', estimate_hours: 20, progress: 0, done: false, created_at: cel`daysAgo(5)`, start_date: cel`daysFromNow(2)`, end_date: cel`daysFromNow(12)`, due_date: cel`daysFromNow(12)` },
52-
{ title: 'Evidence collection', project: { externalId: 'Compliance Audit' }, assignee: 'grace@example.com', status: 'backlog', priority: 'medium', estimate_hours: 18, progress: 0, done: false, created_at: cel`daysAgo(1)`, due_date: cel`daysFromNow(25)` },
53-
{ title: 'App wireframes', project: { externalId: 'Mobile App' }, assignee: 'ada@example.com', status: 'done', priority: 'medium', estimate_hours: 16, progress: 100, done: true, created_at: cel`daysAgo(10)`, start_date: cel`daysAgo(10)`, end_date: cel`daysAgo(6)`, due_date: cel`daysAgo(6)` },
47+
{ title: 'Audit current IA', project: { externalId: 'Website Relaunch' }, assignee: 'ada@example.com', status: 'done', priority: 'medium', estimate_hours: 8, progress: 100, done: true, created_at: cel`daysAgo(20)`, start_date: cel`daysAgo(20)`, end_date: cel`daysAgo(18)`, due_date: cel`daysAgo(18)`, location: { lat: 47.6062, lng: -122.3321 } },
48+
{ title: 'Design system', project: { externalId: 'Website Relaunch' }, assignee: 'ada@example.com', status: 'in_review', priority: 'high', estimate_hours: 24, progress: 80, done: false, created_at: cel`daysAgo(14)`, start_date: cel`daysAgo(12)`, end_date: cel`daysFromNow(2)`, due_date: cel`daysFromNow(2)`, location: { lat: 37.7749, lng: -122.4194 } },
49+
{ title: 'Build homepage', project: { externalId: 'Website Relaunch' }, assignee: 'sam@example.com', status: 'in_progress', priority: 'high', estimate_hours: 40, progress: 45, done: false, created_at: cel`daysAgo(8)`, start_date: cel`daysAgo(6)`, end_date: cel`daysFromNow(10)`, due_date: cel`daysFromNow(10)`, location: { lat: 40.7128, lng: -74.0060 } },
50+
{ title: 'SEO migration plan', project: { externalId: 'Website Relaunch' }, assignee: 'sam@example.com', status: 'todo', priority: 'medium', estimate_hours: 16, progress: 0, done: false, created_at: cel`daysAgo(3)`, start_date: cel`daysFromNow(5)`, end_date: cel`daysFromNow(15)`, due_date: cel`daysFromNow(15)`, location: { lat: 30.2672, lng: -97.7431 } },
51+
{ title: 'Content backlog', project: { externalId: 'Website Relaunch' }, assignee: 'grace@example.com', status: 'backlog', priority: 'low', estimate_hours: 12, progress: 0, done: false, created_at: cel`daysAgo(2)`, due_date: cel`daysFromNow(30)`, location: { lat: 41.8781, lng: -87.6298 } },
52+
{ title: 'Ingest pipeline', project: { externalId: 'Data Platform' }, assignee: 'linus@example.com', status: 'in_progress', priority: 'urgent', estimate_hours: 60, progress: 55, done: false, created_at: cel`daysAgo(40)`, start_date: cel`daysAgo(35)`, end_date: cel`daysFromNow(20)`, due_date: cel`daysFromNow(20)`, location: { lat: 39.7392, lng: -104.9903 } },
53+
{ title: 'Warehouse schema', project: { externalId: 'Data Platform' }, assignee: 'linus@example.com', status: 'in_review', priority: 'high', estimate_hours: 30, progress: 90, done: false, created_at: cel`daysAgo(25)`, start_date: cel`daysAgo(22)`, end_date: cel`daysFromNow(3)`, due_date: cel`daysFromNow(3)`, location: { lat: 42.3601, lng: -71.0589 } },
54+
{ title: 'PII access review', project: { externalId: 'Compliance Audit' }, assignee: 'grace@example.com', status: 'todo', priority: 'urgent', estimate_hours: 20, progress: 0, done: false, created_at: cel`daysAgo(5)`, start_date: cel`daysFromNow(2)`, end_date: cel`daysFromNow(12)`, due_date: cel`daysFromNow(12)`, location: { lat: 38.9072, lng: -77.0369 } },
55+
{ title: 'Evidence collection', project: { externalId: 'Compliance Audit' }, assignee: 'grace@example.com', status: 'backlog', priority: 'medium', estimate_hours: 18, progress: 0, done: false, created_at: cel`daysAgo(1)`, due_date: cel`daysFromNow(25)`, location: { lat: 34.0522, lng: -118.2437 } },
56+
{ title: 'App wireframes', project: { externalId: 'Mobile App' }, assignee: 'ada@example.com', status: 'done', priority: 'medium', estimate_hours: 16, progress: 100, done: true, created_at: cel`daysAgo(10)`, start_date: cel`daysAgo(10)`, end_date: cel`daysAgo(6)`, due_date: cel`daysAgo(6)`, location: { lat: 45.5152, lng: -122.6784 } },
5457
],
5558
});
5659

0 commit comments

Comments
 (0)