candle close alert

This commit is contained in:
yash 2026-04-27 20:34:48 +03:00
parent 30a7f1b68c
commit dd03cae0f3
10 changed files with 328 additions and 60 deletions

View file

@ -0,0 +1,7 @@
alter table alert drop column timeframe;
-- PostgreSQL does not support removing enum values; recreate the type without close_above/close_below.
alter table alert alter column condition type text;
drop type alert_condition;
create type alert_condition as enum ('above', 'below');
alter table alert alter column condition type alert_condition using condition::alert_condition;

View file

@ -0,0 +1,4 @@
alter type alert_condition add value 'close_above';
alter type alert_condition add value 'close_below';
alter table alert add column timeframe text;

View file

@ -0,0 +1 @@
alter table alert drop column created_at;

View file

@ -0,0 +1 @@
alter table alert add column created_at timestamptz not null default now();