ash_hq/priv/repo/migrations/20220327044138_migrate_resources3.exs
2022-03-27 17:26:35 -04:00

32 lines
No EOL
791 B
Elixir

defmodule AshHq.Repo.Migrations.MigrateResources3 do
@moduledoc """
Updates resources based on their most recent snapshots.
This file was autogenerated with `mix ash_postgres.generate_migrations`
"""
use Ecto.Migration
def up do
create table(:guides, primary_key: false) do
add :id, :uuid, null: false, primary_key: true
add :order, :bigint, null: false
add :name, :text, null: false
add :text, :text, null: false
add :library_version_id,
references(:library_versions,
column: :id,
name: "guides_library_version_id_fkey",
type: :uuid
),
null: false
end
end
def down do
drop constraint(:guides, "guides_library_version_id_fkey")
drop table(:guides)
end
end