Sha256: 01e088f6b9653b5a78faa4e5cef8869a7581565bce0800151b106371c7e748ca

Contents?: true

Size: 1.41 KB

Versions: 4

Compression:

Stored size: 1.41 KB

Contents

module XeroGateway
  class Organisation < BaseRecord
    attributes({
      "OrganisationID"        => :string,
      "Name" 	                => :string,     # Display name of organisation shown in Xero
      "LegalName"             => :string,	    # Organisation name shown on Reports
      "PaysTax" 	            => :boolean,    # Boolean to describe if organisation is registered with a local tax authority i.e. true, false
      "Version"   	          => :string,     # See Version Types
      "BaseCurrency"          => :string,     # Default currency for organisation. See Currency types
      "OrganisationType"      => :string,     # only returned for "real" (i.e non-demo) companies
      "OrganisationStatus"    => :string,
      "IsDemoCompany"         => :boolean,
      "APIKey"                => :string,     # returned if organisations are linked via Xero Network
      "CountryCode"           => :string,
      "TaxNumber"             => :string,
      "FinancialYearEndDay"   => :string,
      "FinancialYearEndMonth" => :string,
      "PeriodLockDate"        => :string,
      "CreatedDateUTC"        => :string,
      "ShortCode"             => :string,
      "Timezone"              => :string,
      "LineOfBusiness"        => :string,
      "Addresses"             => [Address]
    })

    def add_address(address_params)
      self.addresses ||= []
      self.addresses << Address.new(address_params)
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
xero_gateway-2.7.0 lib/xero_gateway/organisation.rb
xero_gateway-2.6.0 lib/xero_gateway/organisation.rb
xero_gateway-2.5.0 lib/xero_gateway/organisation.rb
xero_gateway-2.4.0 lib/xero_gateway/organisation.rb