Sha256: b8cd72870452090ebd0923eeb980aeab9f0473259420072791eb206fa229be7f

Contents?: true

Size: 629 Bytes

Versions: 6

Compression:

Stored size: 629 Bytes

Contents

# This migration comes from spree (originally 20140718195325)
class CreateFriendlyIdSlugs < ActiveRecord::Migration
  def change
    create_table :friendly_id_slugs do |t|
      t.string   :slug,           :null => false
      t.integer  :sluggable_id,   :null => false
      t.string   :sluggable_type, :limit => 50
      t.string   :scope
      t.datetime :created_at
    end
    add_index :friendly_id_slugs, :sluggable_id
    add_index :friendly_id_slugs, [:slug, :sluggable_type]
    add_index :friendly_id_slugs, [:slug, :sluggable_type, :scope], :unique => true
    add_index :friendly_id_slugs, :sluggable_type
  end
end

Version data entries

6 entries across 6 versions & 3 rubygems

Version Path
spree_weight_calculator-0.1.0 test/dummy/db/migrate/20160723192596_create_friendly_id_slugs.spree.rb
spree_order_reporting-0.0.3 spec/dummy/db/migrate/20160708163193_create_friendly_id_slugs.spree.rb
spree_order_reporting-0.0.2 spec/dummy/db/migrate/20160707103518_create_friendly_id_slugs.spree.rb
spree_order_reporting-0.0.1 spec/dummy/db/migrate/20160706112470_create_friendly_id_slugs.spree.rb
sprangular-0.1.0 spec/dummy/db/migrate/20141203183775_create_friendly_id_slugs.spree.rb
sprangular-0.0.1 spec/dummy/db/migrate/20141203183775_create_friendly_id_slugs.spree.rb