Module: Quickbooks
- Defined in:
- lib/quickbooks/model/item.rb,
lib/quickbooks.rb,
lib/quickbooks/version.rb,
lib/quickbooks/service/item.rb,
lib/quickbooks/util/logging.rb,
lib/quickbooks/model/invoice.rb,
lib/quickbooks/model/customer.rb,
lib/quickbooks/model/meta_data.rb,
lib/quickbooks/service/invoice.rb,
lib/quickbooks/model/base_model.rb,
lib/quickbooks/service/customer.rb,
lib/quickbooks/model/custom_field.rb,
lib/quickbooks/model/customer_ref.rb,
lib/quickbooks/model/email_address.rb,
lib/quickbooks/service/base_service.rb,
lib/quickbooks/service/service_crud.rb,
lib/quickbooks/model/invoice_item_ref.rb,
lib/quickbooks/model/physical_address.rb,
lib/quickbooks/model/telephone_number.rb,
lib/quickbooks/model/web_site_address.rb,
lib/quickbooks/model/discount_override.rb,
lib/quickbooks/model/invoice_line_item.rb,
lib/quickbooks/model/linked_transaction.rb,
lib/quickbooks/model/payment_line_detail.rb,
lib/quickbooks/model/sub_total_line_detail.rb,
lib/quickbooks/model/sales_item_line_detail.rb
Overview
Business Rules
- The DisplayName, GivenName, MiddleName, FamilyName, and PrintOnCheckName attributes must not contain a colon,":".
- The DisplayName attribute must be unique across all other customers, employees, vendors, and other names.
- The PrimaryEmailAddress attribute must contain an at sign, "@," and dot, ".".
- Nested customer objects can be used to define sub-customers, jobs, or a combination of both, under a parent.
- Up to four levels of nesting can be defined under a top-level customer object.
- The Job attribute defines whether the object is a top-level customer or nested sub-customer/job.
- Either the DisplayName attribute or at least one of Title, GivenName, MiddleName, FamilyName, Suffix, or FullyQualifiedName attributes are required during create.
Defined Under Namespace
Modules: Model, Service, Util
Classes: Collection
Constant Summary
collapse
- VERSION =
"0.0.1"
- @@logger =
nil
Class Attribute Summary collapse
Class Method Summary
collapse
Class Attribute Details
.log(msg) ⇒ Object
63
64
65
66
67
68
|
# File 'lib/quickbooks.rb', line 63
def log(msg)
if log?
logger.info(msg)
logger.flush if logger.respond_to?(:flush)
end
end
|
Class Method Details
.log? ⇒ Boolean
Returns whether to log. Defaults to 'false'.
59
60
61
|
# File 'lib/quickbooks.rb', line 59
def log?
@log ||= false
end
|
.logger ⇒ Object
47
48
49
|
# File 'lib/quickbooks.rb', line 47
def logger
@@logger ||= ::Logger.new($stdout) end
|
.logger=(logger) ⇒ Object
51
52
53
|
# File 'lib/quickbooks.rb', line 51
def logger=(logger)
@@logger = logger
end
|