Sha256: 5a1cf542bbd719e11c0b2e319aa2ebcb02e2bb79ab19b993cad89af0f5f657e4

Contents?: true

Size: 681 Bytes

Versions: 17

Compression:

Stored size: 681 Bytes

Contents

class CreateEcmCmsNavigationItems < ActiveRecord::Migration
  def change
    create_table :ecm_cms_navigation_items do |t|
      t.string :name
      t.string :url
      t.string :key
      t.string :options

      # associations
      t.references :ecm_cms_navigation
      t.references :ecm_cms_page

      # awesome nested set
      t.references :parent
      t.integer :children_count, :default => 0, :null => false
      t.integer :lft
      t.integer :rgt
      t.integer :depth

      # friendly id
      t.string :slug

      t.timestamps
    end
    add_index :ecm_cms_navigation_items, :ecm_cms_navigation_id
    add_index :ecm_cms_navigation_items, :parent_id
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
ecm_cms-1.0.5.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-1.0.4.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-1.0.3.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-1.0.2.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-1.0.1.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-1.0.0.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.13.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.11.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.10.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.8.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.7.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.6.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.5.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.4.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.3.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.2.pre db/migrate/006_create_ecm_cms_navigation_items.rb
ecm_cms-0.0.1.pre db/migrate/006_create_ecm_cms_navigation_items.rb