Class: Dina::Person

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/dina/models/person.rb

Class Method Summary collapse

Methods inherited from BaseModel

custom_headers, #english_description, find_by_group, #french_description, site

Class Method Details

.endpoint_pathObject



22
23
24
# File 'lib/dina/models/person.rb', line 22

def self.endpoint_path
  "agent-api/"
end

.find_by_email(email) ⇒ Object

Finds a Person object using an email address

Parameters:

  • email (String)

    an email address



34
35
36
# File 'lib/dina/models/person.rb', line 34

def self.find_by_email(email)
  where("email": email).all.first
end

.table_nameObject



26
27
28
# File 'lib/dina/models/person.rb', line 26

def self.table_name
  "person"
end