Class: Quickeebooks::Online::Model::IntuitType

Inherits:
Object
  • Object
show all
Includes:
Logging, ROXML
Defined in:
lib/quickeebooks/online/model/intuit_type.rb

Class Method Summary collapse

Methods included from Logging

#log

Class Method Details

.resource_for_collectionObject

These can be over-ridden in each model object as needed For the most part a model object has a single resource for all operations E.g. <baseURL>/resource/invoice/v2/<realmID> But for the Account object its collection is plural while all other operations are singular E.g. Fetch all accounts: <baseURL>/resource/accounts/v2/<realmID>

vs

Create an account, fetch an account, etc: <baseURL>/resource/account/v2/<realmID>



17
18
19
# File 'lib/quickeebooks/online/model/intuit_type.rb', line 17

def self.resource_for_collection
  "#{self::REST_RESOURCE}s"
end

.resource_for_singularObject



21
22
23
# File 'lib/quickeebooks/online/model/intuit_type.rb', line 21

def self.resource_for_singular
  self::REST_RESOURCE
end