Module: AR::UUID::Schema

Defined in:
lib/ar/uuid/schema.rb

Instance Method Summary collapse

Instance Method Details

#add_reference(table_name, ref_name, options = {}) ⇒ Object



11
12
13
14
# File 'lib/ar/uuid/schema.rb', line 11

def add_reference(table_name, ref_name, options = {})
  options[:type] = :uuid unless options.key?(:type)
  super(table_name, ref_name, **options)
end

#create_table(table_name, options = {}, &block) ⇒ Object



6
7
8
9
# File 'lib/ar/uuid/schema.rb', line 6

def create_table(table_name, options = {}, &block)
  options[:id] = :uuid unless options.key?(:id)
  super(table_name, **options, &block)
end