Sha256: d02d057482645ff822c776462361fa8d3a8a80b3294bedaea43e5a4779f7dff7

Contents?: true

Size: 560 Bytes

Versions: 6

Compression:

Stored size: 560 Bytes

Contents

# This migration comes from ecm_cms_engine (originally 1)
class CreateEcmCmsFolders < ActiveRecord::Migration
  def change
    create_table :ecm_cms_folders do |t|
      t.string :basename
      t.string :pathname

      # associations
      t.integer :children_count, default: 0, null: false
      t.integer :ecm_cms_templates_count, default: 0, null: false

      # awesome nested set
      t.references :parent
      t.integer :lft
      t.integer :rgt
      t.integer :depth

      t.timestamps
    end
    add_index :ecm_cms_folders, :parent_id
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
ecm_cms2_backend-1.2.1 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb
ecm_cms2_backend-1.2.0 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb
ecm_cms2_backend-1.1.0 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb
ecm_cms2_backend-1.0.5 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb
ecm_cms2_backend-1.0.4 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb
ecm_cms2_backend-1.0.3 spec/dummy/db/migrate/20151126215840_create_ecm_cms_folders.ecm_cms_engine.rb