person.rb

Path: app/models/person.rb
Last Update: Fri Nov 23 13:53:40 +1100 2007

People have many names (through acts_as_nameable) but belong to one surname. This allows many people to share a surname (unlike other personal names).

Because of the way names for people work there is a lot of complication in using name types (e.g. distinguishing between first names and surnames). These conventions represent common English usage, but may not generalise across communities, and may need to be adapted.

There are a lot of find/create by name style methods to make it easier to automatically build up a list of people for things like importing from Our Story. They are not necessarily used by PeopleController.

*schema.rb* snippet:

  create_table "people", :force => true do |t|
    t.column "sex",           :string,  :limit => 16
    t.column "language_id",   :integer
    t.column "date_of_birth", :date
    t.column "date_of_death", :date
    t.column "description",   :text
    t.column "clan_id",       :integer
    t.column "surname_id",    :integer
    t.column "restriction",   :string
  end

[Validate]