Add all
This commit is contained in:
parent
b35e18cd20
commit
82f55f7afe
80 changed files with 6687 additions and 5 deletions
23
priv/repo/migrations/20250702091405_create_notes.exs
Normal file
23
priv/repo/migrations/20250702091405_create_notes.exs
Normal file
|
@ -0,0 +1,23 @@
|
|||
defmodule Nulla.Repo.Migrations.CreateNotes do
|
||||
use Ecto.Migration
|
||||
|
||||
def change do
|
||||
create table(:notes, primary_key: false) do
|
||||
add :id, :bigint, primary_key: true
|
||||
add :inReplyTo, :string
|
||||
add :published, :utc_datetime
|
||||
add :url, :string
|
||||
add :visibility, :string
|
||||
add :to, {:array, :string}
|
||||
add :cc, {:array, :string}
|
||||
add :sensitive, :boolean, default: false, null: false
|
||||
add :content, :string
|
||||
add :language, :string
|
||||
add :actor_id, references(:actors, on_delete: :delete_all)
|
||||
|
||||
timestamps(type: :utc_datetime)
|
||||
end
|
||||
|
||||
create index(:notes, [:actor_id])
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue