Sha256: 3b9c796c414c6434adcc2a6bd131d438bcf78c959ef61852604f11d0f738a72a

Contents?: true

Size: 691 Bytes

Versions: 8

Compression:

Stored size: 691 Bytes

Contents

# frozen_string_literal: true

ActiveRecord::Schema.define(version: 0) do
  create_table :nodes do |t|
    t.integer :parent_id
    t.string :name
    t.boolean :active, default: true
  end

  add_foreign_key(:nodes, :nodes, column: :parent_id)

  create_table :node_infos do |t|
    t.belongs_to :node
    t.string :status
  end

  create_table :node_with_other_parent_keys do |t|
    t.integer :other_id
  end

  create_table :node_with_polymorphic_parents do |t|
    t.integer :other_id
    t.string :other_type
  end

  create_table :locations do |t|
    t.integer :parent_id
    t.string :name
    t.string :type
  end

  add_foreign_key(:locations, :locations, column: :parent_id)
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
acts_as_recursive_tree-4.1.0 spec/db/schema.rb
acts_as_recursive_tree-4.0.0 spec/db/schema.rb
acts_as_recursive_tree-3.5.0 spec/db/schema.rb
acts_as_recursive_tree-3.4.0 spec/db/schema.rb
acts_as_recursive_tree-3.3.0 spec/db/schema.rb
acts_as_recursive_tree-3.2.0 spec/db/schema.rb
acts_as_recursive_tree-3.1.0 spec/db/schema.rb
acts_as_recursive_tree-3.0.0 spec/db/schema.rb