Module: Attached::Definition

Defined in:
lib/attached/definition.rb

Instance Method Summary collapse

Instance Method Details

#attachment(*args) ⇒ Object



5
6
7
8
9
10
11
12
# File 'lib/attached/definition.rb', line 5

def attachment(*args)
  options = args.extract_options!
  args.each do |name|
    column("#{name}_identifier", :string, options)
    column("#{name}_extension", :string, options)
    column("#{name}_size", :integer, options)
  end
end