Expand dashboard analytics and document production implementation
This commit is contained in:
10
mockups/db/006_daily_health_reports.sql
Normal file
10
mockups/db/006_daily_health_reports.sql
Normal file
@@ -0,0 +1,10 @@
|
||||
SET search_path TO analytics, public;
|
||||
CREATE TABLE daily_health_reports (
|
||||
game_id bigint NOT NULL REFERENCES games(id),
|
||||
report_date date NOT NULL,
|
||||
period_days integer NOT NULL CHECK(period_days IN (1,7)),
|
||||
generated_at timestamptz NOT NULL DEFAULT now(),
|
||||
payload jsonb NOT NULL,
|
||||
PRIMARY KEY(game_id,report_date,period_days)
|
||||
);
|
||||
INSERT INTO schema_migrations(version) VALUES('006_daily_health_reports');
|
||||
Reference in New Issue
Block a user