* fix(widget-secrets): add missing widget_secret migration and add error notifications The widget_secret table was defined in all three Drizzle schema files but no SQL migration was ever generated to create it, causing setSecret to fail with 'no such table: widget_secret' in production (drizzle-kit push in development hid the problem). - Add migration SQL for sqlite (0040), mysql (0042), postgresql (0008) - Update journal entries for all three dialects - Add onError handlers to setSecret/deleteSecret mutations so errors are shown as red notifications instead of silently swallowed Fixes #6186 * fix(widget-secrets): add missing drizzle snapshots for merge-url and widget_secret migrations The merge_custom_widget_url migration (0039/0041/0007) was committed without a corresponding snapshot, breaking drizzle-kit generate for all future migrations. This adds: - 0039/0041/0007 snapshots reflecting the merge-url changes (base_url+endpoint -> url, add enabled column) - 0040/0042/0008 snapshots reflecting the widget_secret table All snapshot chains now match journal entries (41/43/9 entries each).
9 lines
259 B
SQL
9 lines
259 B
SQL
CREATE TABLE `widget_secret` (
|
|
`item_id` text NOT NULL,
|
|
`kind` text NOT NULL,
|
|
`value` text NOT NULL,
|
|
`updated_at` integer NOT NULL,
|
|
PRIMARY KEY(`item_id`, `kind`),
|
|
FOREIGN KEY (`item_id`) REFERENCES `item`(`id`) ON UPDATE no action ON DELETE cascade
|
|
);
|