Class: Clearbooks::AccountCode
- Defined in:
- lib/clearbooks/model/account_code.rb
Overview
Instance Attribute Summary collapse
-
#account_name ⇒ String
readonly
Optional.
-
#default_vat_rate ⇒ String
readonly
Optional.
-
#group_name ⇒ String
readonly
Optional.
-
#id ⇒ Fixnum
readonly
Optional.
-
#show_purchases ⇒ Boolean
readonly
Optional.
-
#show_sales ⇒ Boolean
readonly
Optional.
Instance Method Summary collapse
-
#initialize(data) ⇒ AccountCode
constructor
A new instance of AccountCode.
Methods inherited from Base
Constructor Details
#initialize(data) ⇒ AccountCode
Returns a new instance of AccountCode.
50 51 52 53 54 55 56 57 58 59 |
# File 'lib/clearbooks/model/account_code.rb', line 50 def initialize data @id = data.savon(:id).to_i @account_name = data.savon :account_name @group_name = data.savon :group_name @default_vat_rate = data.savon :default_vat_rate @show_sales = data.savon(:show_sales).to_b @show_purchases = data.savon(:show_purchases).to_b end |
Instance Attribute Details
#account_name ⇒ String (readonly)
Optional.
21 22 23 |
# File 'lib/clearbooks/model/account_code.rb', line 21 def account_name @account_name end |
#default_vat_rate ⇒ String (readonly)
Optional.
31 32 33 |
# File 'lib/clearbooks/model/account_code.rb', line 31 def default_vat_rate @default_vat_rate end |
#group_name ⇒ String (readonly)
Optional. The name of the group the account code is assigned to.
26 27 28 |
# File 'lib/clearbooks/model/account_code.rb', line 26 def group_name @group_name end |
#id ⇒ Fixnum (readonly)
Optional. The internal id of the account code.
16 17 18 |
# File 'lib/clearbooks/model/account_code.rb', line 16 def id @id end |
#show_purchases ⇒ Boolean (readonly)
Optional. Boolean value of whether the account code shows in the purchase invoice form.
41 42 43 |
# File 'lib/clearbooks/model/account_code.rb', line 41 def show_purchases @show_purchases end |
#show_sales ⇒ Boolean (readonly)
Optional. Boolean value of whether the account code shows in the sales invoice form.
36 37 38 |
# File 'lib/clearbooks/model/account_code.rb', line 36 def show_sales @show_sales end |