Class: Person

Inherits:
ActiveRecord::Base
  • Object
show all
Includes:
Merger
Defined in:
app/models/person.rb

Instance Method Summary collapse

Instance Method Details

#full_name(*options) ⇒ Object



8
9
10
11
12
13
14
15
# File 'app/models/person.rb', line 8

def full_name(*options)
  options = options.extract_options!
  if options[:last_name_first]
    "#{last_name}, #{first_name} #{middle_name}".squeeze(' ').strip
  else  
    "#{first_name} #{middle_name} #{last_name}".squeeze(' ').strip
  end
end