Sha256: cb2f8ac0c825cc795ab2d1ed296fcb3595042c106986155d88876529d4305ba4

Contents?: true

Size: 677 Bytes

Versions: 21

Compression:

Stored size: 677 Bytes

Contents

class CreateEmailbutlerTables < ActiveRecord::Migration<%= migration_version %>
  def self.up
    enable_extension 'uuid-ossp' unless extensions.include?('uuid-ossp')

    create_table :emailbutler_messages do |t|
      t.uuid :uuid, null: false, default: ''
      t.string :mailer, null: false
      t.string :action, null: false
      t.jsonb :params, null: false, default: {}
      t.string :send_to, array: true
      t.integer :status, null: false, default: 0
      t.datetime :timestamp
      t.integer :lock_version
      t.timestamps
    end
    add_index :emailbutler_messages, :uuid, unique: true
  end

  def self.down
    drop_table :emailbutler_messages
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
emailbutler-0.8.8 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.7 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.6 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.5 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.4 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.3 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.2 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.8.1 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.6 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.5 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.4 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.3 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.2 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.1 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.7.0 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.6.1 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.6.0 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.5.9 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.5.8 lib/generators/emailbutler/templates/migration.erb
emailbutler-0.5.7 lib/generators/emailbutler/templates/migration.erb