change(ui): highlights messages to be nullable

This commit is contained in:
Shekar Siri 2025-02-10 12:21:20 +01:00
parent 5267a1c830
commit 3191843829
5 changed files with 12 additions and 4 deletions

View file

@ -1396,7 +1396,7 @@ class SearchNoteSchema(_PaginatedSchema):
class SessionNoteSchema(BaseModel):
message: str = Field(..., min_length=2)
message: Optional[str] = Field(..., min_length=2)
tag: Optional[str] = Field(default=None)
timestamp: int = Field(default=-1)
is_public: bool = Field(default=False)

View file

@ -26,6 +26,13 @@ WHERE metrics.metric_type = 'insights';
DROP TABLE IF EXISTS public.user_favorite_errors;
DROP TABLE IF EXISTS public.user_viewed_errors;
ALTER TABLE IF EXISTS public.sessions_notes
ADD COLUMN start_at integer,
ADD COLUMN end_at integer,
ADD COLUMN thumbnail text,
ADD COLUMN updated_at timestamp DEFAULT NULL,
ALTER COLUMN message DROP NOT NULL;
COMMIT;
\elif :is_next

View file

@ -929,7 +929,7 @@ EXECUTE PROCEDURE notify_alert();
CREATE TABLE public.sessions_notes
(
note_id integer generated BY DEFAULT AS IDENTITY PRIMARY KEY,
message text NOT NULL,
message text NULL DEFAULT NULL,
created_at timestamp without time zone NOT NULL DEFAULT (now() at time zone 'utc'),
user_id integer NULL REFERENCES public.users (user_id) ON DELETE SET NULL,
deleted_at timestamp without time zone NULL DEFAULT NULL,

View file

@ -30,7 +30,8 @@ ALTER TABLE IF EXISTS public.sessions_notes
ADD COLUMN start_at integer,
ADD COLUMN end_at integer,
ADD COLUMN thumbnail text,
ADD COLUMN updated_at timestamp DEFAULT NULL;
ADD COLUMN updated_at timestamp DEFAULT NULL,
ALTER COLUMN message DROP NOT NULL;
COMMIT;

View file

@ -889,7 +889,7 @@ EXECUTE PROCEDURE notify_alert();
CREATE TABLE public.sessions_notes
(
note_id integer generated BY DEFAULT AS IDENTITY PRIMARY KEY,
message text NOT NULL,
message text NULL DEFAULT NULL,
created_at timestamp without time zone NOT NULL DEFAULT (now() at time zone 'utc'),
user_id integer NULL REFERENCES public.users (user_id) ON DELETE SET NULL,
deleted_at timestamp without time zone NULL DEFAULT NULL,