feat: add public bank sync failure ops

This commit is contained in:
Codex
2026-06-30 09:12:45 +08:00
parent d1cb341351
commit 959e612211
14 changed files with 484 additions and 44 deletions

View File

@@ -0,0 +1,14 @@
alter table public.tenant_content_notifications
drop constraint if exists tenant_content_notifications_notification_type_check;
alter table public.tenant_content_notifications
add constraint tenant_content_notifications_notification_type_check
check (notification_type in (
'public_question_bank_synced',
'public_question_bank_conflict',
'public_question_bank_sync_failed'
));
create index if not exists idx_tenant_question_bank_adoptions_sync_ops
on public.tenant_question_bank_adoptions(sync_status, updated_at desc)
where sync_status in ('pending', 'failed');