Sha256: c372a7a24a5943220f22dba1882a95fe5bfa8f6a9f792514146cbec01f3e8209
Contents?: true
Size: 873 Bytes
Versions: 8
Compression:
Stored size: 873 Bytes
Contents
class CreateOpportunities < ActiveRecord::Migration[4.2] def self.up create_table :opportunities, force: true do |t| t.string :uuid, limit: 36 t.references :user t.references :campaign t.integer :assigned_to t.string :name, limit: 64, null: false, default: "" t.string :access, limit: 8, default: "Public" # %w(Private Public Shared) t.string :source, limit: 32 t.string :stage, limit: 32 t.integer :probability t.decimal :amount, precision: 12, scale: 2 t.decimal :discount, precision: 12, scale: 2 t.date :closes_on t.datetime :deleted_at t.timestamps end add_index :opportunities, %i[user_id name deleted_at], unique: true, name: 'id_name_deleted' add_index :opportunities, :assigned_to end def self.down drop_table :opportunities end end
Version data entries
8 entries across 8 versions & 1 rubygems