class Person

Attributes

admin[RW]
attachable_sgid[RW]
avatar_url[RW]
bio[RW]
company[RW]
created_at[RW]
email_address[RW]
name[RW]
owner[RW]
personable_type[RW]
time_zone[RW]
title[RW]
updated_at[RW]

Public Class Methods

new(json) click to toggle source
# File lib/messenger/models/person.rb, line 21
def initialize(json)
  @id = json['id']
  @attachable_sgid = json['attachable_sgid']
  @name = json['name']
  @email_address = json['email_address']
  @personable_type = json['personable_type']
  @title = json['title']
  @bio = json['bio']
  @created_at = Time.parse(json['created_at'])
  @updated_at = Time.parse(json['updated_at'])
  @admin = json['admin']
  @owner = json['owner']
  @time_zone = json['time_zone']
  @avatar_url = json['avatar_url']

  @company = Company.new
  @company.id = json['company']['id']
  @company.name = json['company']['name']
end