mirror of
https://github.com/bonfire-networks/bonfire-app.git
synced 2024-05-15 07:32:42 +00:00
18 lines
398 B
Elixir
18 lines
398 B
Elixir
|
defmodule Rauversion.Repo.Migrations.CreatePurchaseOrders do
|
||
|
use Ecto.Migration
|
||
|
|
||
|
def change do
|
||
|
create table(:purchase_orders) do
|
||
|
add(:total, :decimal)
|
||
|
add(:promo_code, :string)
|
||
|
add(:data, :map)
|
||
|
add(:state, :string)
|
||
|
add(:user_id, RauversionExtension.user_table_reference())
|
||
|
|
||
|
timestamps()
|
||
|
end
|
||
|
|
||
|
create(index(:purchase_orders, [:user_id]))
|
||
|
end
|
||
|
end
|