-- Seed data for the SaaS Spend Tracker schema, from section 14 of the blueprint. Load after saas-spend-tracker.sql. -- T (the day the seed is loaded) is fixed to Tue 13 Oct 2026, the date the spec's examples use. Time zone UTC. -- The spec gives no times for the seed history; created rows use 09:00 on T and the two status changes 09:05. INSERT INTO people (id, name, email, is_admin, active) VALUES ('person-dana', 'Dana Ruiz', 'dana@northwind.example', TRUE, TRUE), ('person-ana', 'Ana Lima', 'ana@northwind.example', TRUE, TRUE), ('person-maya', 'Maya Chen', 'maya@northwind.example', FALSE, TRUE), ('person-sam', 'Sam Okafor', 'sam@northwind.example', FALSE, TRUE), ('person-ben', 'Ben Cho', 'ben@northwind.example', FALSE, TRUE), ('person-jo', 'Jo Park', 'jo@northwind.example', FALSE, TRUE), ('person-lee', 'Lee Park', 'lee@northwind.example', FALSE, TRUE); INSERT INTO departments (id, name) VALUES ('department-design', 'Design'), ('department-engineering', 'Engineering'), ('department-finance', 'Finance'), ('department-it', 'IT'), ('department-ops', 'Ops'); -- Prices are per billing cycle, in cents. Monday.com and Loom changed status after creation, so their version is 2. INSERT INTO tools (id, name, owner_id, department_id, billing_cycle, cycle_price_cents, renews_on, auto_renew, notice_days, seats_purchased, seats_used, status, status_reason, ended_on, link, notes, version, created_at, updated_at) VALUES ('tool-figma', 'Figma', 'person-maya', 'department-design', 'annual', 960000, '2026-11-12', FALSE, 0, 20, 14, 'active', NULL, NULL, NULL, NULL, 1, '2026-10-13 09:00:00', '2026-10-13 09:00:00'), ('tool-notion', 'Notion', 'person-dana', 'department-ops', 'monthly', 100000, '2026-10-20', TRUE, 0, 100, 72, 'active', NULL, NULL, NULL, NULL, 1, '2026-10-13 09:00:00', '2026-10-13 09:00:00'), ('tool-zoom', 'Zoom', 'person-ben', 'department-it', 'annual', 720000, '2026-12-01', TRUE, 30, 40, 25, 'active', NULL, NULL, NULL, NULL, 1, '2026-10-13 09:00:00', '2026-10-13 09:00:00'), ('tool-github', 'GitHub', 'person-sam', 'department-engineering', 'monthly', 21000, '2026-11-01', TRUE, 0, 30, 30, 'active', NULL, NULL, NULL, NULL, 1, '2026-10-13 09:00:00', '2026-10-13 09:00:00'), ('tool-monday', 'Monday.com', 'person-dana', 'department-ops', 'annual', 240000, '2026-10-25', TRUE, 14, 20, 0, 'cancelling', 'Nobody has used it since we moved to Notion', NULL, NULL, NULL, 2, '2026-10-13 09:00:00', '2026-10-13 09:05:00'), ('tool-loom', 'Loom', 'person-maya', 'department-design', 'annual', 150000, '2026-08-29', TRUE, 30, 15, 0, 'cancelled', 'Replaced by Zoom recordings', '2026-08-29', NULL, NULL, 2, '2026-10-13 09:00:00', '2026-10-13 09:05:00'); -- Seed history: created by Ana Lima for each tool, and the two status changes. -- Monday.com's notice deadline was Oct 11 (Oct 25 minus 14 days), so a change stamped on T is late notice under section 8. INSERT INTO history_events (id, tool_id, actor_id, type, source, changes, reason, created_at) VALUES ('history-figma-1', 'tool-figma', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-notion-1', 'tool-notion', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-zoom-1', 'tool-zoom', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-github-1', 'tool-github', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-monday-1', 'tool-monday', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-loom-1', 'tool-loom', 'person-ana', 'created', 'form', NULL, NULL, '2026-10-13 09:00:00'), ('history-monday-2', 'tool-monday', 'person-dana', 'status_changed', 'form', '{"status": {"from": "active", "to": "cancelling"}, "late_notice": true}', 'Nobody has used it since we moved to Notion', '2026-10-13 09:05:00'), ('history-loom-2', 'tool-loom', 'person-maya', 'status_changed', 'form', '{"status": {"from": "active", "to": "cancelled"}, "ended_on": {"from": null, "to": "2026-08-29"}}', 'Replaced by Zoom recordings', '2026-10-13 09:05:00'); INSERT INTO settings (id, currency_code, time_zone, dev_clock_offset_days) VALUES (1, 'USD', 'UTC', 0);