mirror of
https://github.com/coder/coder.git
synced 2026-10-16 14:48:56 +08:00
Removes the six Coder Tasks notification templates (their preferences and inbox history go with them via cascade) and the `preference_task_notification_alert_dismissed` user setting with its two queries. The `task` value of `ai_seat_usage_reason` stays: seats consumed through tasks remain consumed, and remapping their reason would misstate billing history. **Breaking change:** migration 000592 deletes data. The down migration restores the template definitions, not the deleted preferences or notification history. **Review changes:** dropped the `ai_seat_state` remap and enum swap and the migration unit test (both per review); moved the migration from 000591 to 000592 because main took 000591. **Stack context:** Coder Tasks removal stack (CODAGT-642): #28743 frontend → #28788 CLI → #28789 API → #28790 provisioner → **#29084 notifications** → #29085 build reasons → #29086 tables → #28750 permissions. The last four PRs replace the single data-drop migration that used to live in #28750; each carries one concern and its own migration number. > Created by Xum (AI agent) on behalf of @ibetitsmike.
16 lines
700 B
SQL
16 lines
700 B
SQL
-- Delete task notification templates and preferences. The delete cascades
|
|
-- to inbox_notifications and notification_messages: historical task
|
|
-- notifications are intentionally removed with the feature.
|
|
DELETE FROM notification_templates
|
|
WHERE id IN (
|
|
'bd4b7168-d05e-4e19-ad0f-3593b77aa90f', -- Task Working
|
|
'd4a6271c-cced-4ed0-84ad-afd02a9c7799', -- Task Idle
|
|
'8c5a4d12-9f7e-4b3a-a1c8-6e4f2d9b5a7c', -- Task Completed
|
|
'3b7e8f1a-4c2d-49a6-b5e9-7f3a1c8d6b4e', -- Task Failed
|
|
'2a74f3d3-ab09-4123-a4a5-ca238f4f65a1', -- Task Paused
|
|
'843ee9c3-a8fb-4846-afa9-977bec578649' -- Task Resumed
|
|
);
|
|
|
|
DELETE FROM user_configs
|
|
WHERE key = 'preference_task_notification_alert_dismissed';
|