defmodule SimpleshopTheme.Repo.Migrations.AddCachedProductFields do
  use Ecto.Migration

  def change do
    alter table(:products) do
      add :cheapest_price, :integer, null: false, default: 0
      add :compare_at_price, :integer
      add :in_stock, :boolean, null: false, default: true
      add :on_sale, :boolean, null: false, default: false
    end
  end
end
