# File lib/ar/uuid/table_definition.rb, line 19 def primary_key(name, type = :primary_key, **options) options[:default] = ::AR::UUID::Utils.uuid_default_function super(name, type, **options) end
module AR::UUID::TableDefinition
Public Instance Methods
primary_key(name, type = :primary_key, **options)
click to toggle source
Calls superclass method
references(*args)
click to toggle source
Calls superclass method
# File lib/ar/uuid/table_definition.rb, line 6 def references(*args) options = args.extract_options! options[:type] = :uuid unless options.include?(:type) unless options.include?(:null) options[:null] = !::AR::UUID::Utils.belongs_to_required_by_default end super(*args, **options) end
Also aliased as: belongs_to