Class: LimdeskApi::Contactperson

Inherits:
LimdeskObject
  • Object
show all
Defined in:
lib/limdesk_api/contactperson.rb

Overview

ContactPerson

Constant Summary collapse

NOT_IMPLEMENTED =
'contactperson currently does not support this call'

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from LimdeskObject

all, #delete!, get, object_symbol, #object_symbol, #refresh!

Class Method Details

.create(params) ⇒ LimdeskApi::Contactperson

Creates a new contact person

Parameters:

  • params (Hash)

    the options to create a contact person with

Options Hash (params):

  • :name (String)

    contact person name

  • :phone (String)

    contact person phone number

  • :email (String)

    contact person email address

  • :client_id (Integer)

    client’s id (parent)

Returns:



14
15
16
# File 'lib/limdesk_api/contactperson.rb', line 14

def self.create(params)
  super
end

Instance Method Details

#allObject



29
30
31
# File 'lib/limdesk_api/contactperson.rb', line 29

def all
  fail Activity::NOT_IMPLEMENTED
end

#update(params) ⇒ LimdeskApi::Contactperson

updates a contact person

Parameters:

  • params (Hash)

    new contact person data

Returns:



23
24
25
26
27
# File 'lib/limdesk_api/contactperson.rb', line 23

def update(params)
  LimdeskApi.put object: object_symbol,
                 params: params,
                 id: id
end