mirror of
https://github.com/plausible/analytics.git
synced 2024-12-02 07:38:47 +03:00
20 lines
463 B
Elixir
20 lines
463 B
Elixir
|
defmodule Plausible.Repo.Migrations.AddEmailReporting do
|
||
|
use Ecto.Migration
|
||
|
|
||
|
def change do
|
||
|
create table(:email_settings) do
|
||
|
add :site_id, references(:sites, on_delete: :delete_all), null: false
|
||
|
|
||
|
timestamps()
|
||
|
end
|
||
|
|
||
|
create table(:sent_email_reports) do
|
||
|
add :site_id, references(:sites, on_delete: :delete_all), null: false
|
||
|
add :year, :integer
|
||
|
add :week, :integer
|
||
|
|
||
|
add :timestamp, :naive_datetime
|
||
|
end
|
||
|
end
|
||
|
end
|