Class: ConnectWise::GLExportPurchaseTransactionDetail
- Inherits:
-
Object
- Object
- ConnectWise::GLExportPurchaseTransactionDetail
- Defined in:
- lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb
Instance Attribute Summary collapse
-
#account_number ⇒ Object
Returns the value of attribute account_number.
-
#cogs_xref ⇒ Object
Returns the value of attribute cogs_xref.
-
#cost ⇒ Object
Returns the value of attribute cost.
-
#cost_account_number ⇒ Object
Returns the value of attribute cost_account_number.
-
#currency ⇒ Object
Returns the value of attribute currency.
-
#description ⇒ Object
Returns the value of attribute description.
-
#document_date ⇒ Object
Returns the value of attribute document_date.
-
#drop_shipped_flag ⇒ Object
Returns the value of attribute drop_shipped_flag.
-
#gl_class ⇒ Object
Returns the value of attribute gl_class.
-
#gl_item_id ⇒ Object
Returns the value of attribute gl_item_id.
-
#gl_type_id ⇒ Object
Returns the value of attribute gl_type_id.
-
#id ⇒ Object
Returns the value of attribute id.
-
#inventory_account_number ⇒ Object
Returns the value of attribute inventory_account_number.
-
#inventory_xref ⇒ Object
Returns the value of attribute inventory_xref.
-
#item ⇒ Object
Returns the value of attribute item.
-
#item_cost ⇒ Object
Returns the value of attribute item_cost.
-
#item_description ⇒ Object
Returns the value of attribute item_description.
-
#item_price ⇒ Object
Returns the value of attribute item_price.
-
#item_type_xref ⇒ Object
Returns the value of attribute item_type_xref.
-
#line_number ⇒ Object
Returns the value of attribute line_number.
-
#location_xref ⇒ Object
Returns the value of attribute location_xref.
-
#memo ⇒ Object
Returns the value of attribute memo.
-
#price_level_xref ⇒ Object
Returns the value of attribute price_level_xref.
-
#purchase_header_tax_group ⇒ Object
Returns the value of attribute purchase_header_tax_group.
-
#quantity ⇒ Object
Returns the value of attribute quantity.
-
#sales_code ⇒ Object
Returns the value of attribute sales_code.
-
#sales_description ⇒ Object
Returns the value of attribute sales_description.
-
#serial_numbers ⇒ Object
Returns the value of attribute serial_numbers.
-
#serialized_flag ⇒ Object
Returns the value of attribute serialized_flag.
-
#shipment_method ⇒ Object
Returns the value of attribute shipment_method.
-
#sub_category ⇒ Object
Returns the value of attribute sub_category.
-
#tax_agency_xref ⇒ Object
Returns the value of attribute tax_agency_xref.
-
#tax_code ⇒ Object
Returns the value of attribute tax_code.
-
#tax_code_xref ⇒ Object
Returns the value of attribute tax_code_xref.
-
#tax_note ⇒ Object
Returns the value of attribute tax_note.
-
#tax_rate ⇒ Object
Returns the value of attribute tax_rate.
-
#taxable ⇒ Object
Returns the value of attribute taxable.
-
#total ⇒ Object
Returns the value of attribute total.
-
#unit_of_measure ⇒ Object
Returns the value of attribute unit_of_measure.
-
#uom_schedule_xref ⇒ Object
Returns the value of attribute uom_schedule_xref.
-
#vendor_account_number ⇒ Object
Returns the value of attribute vendor_account_number.
-
#vendor_number ⇒ Object
Returns the value of attribute vendor_number.
-
#warehouse_bin ⇒ Object
Returns the value of attribute warehouse_bin.
-
#warehouse_site ⇒ Object
Returns the value of attribute warehouse_site.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
-
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ GLExportPurchaseTransactionDetail
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ GLExportPurchaseTransactionDetail
Initializes the object
198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 198 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v} if attributes.has_key?(:'id') self.id = attributes[:'id'] end if attributes.has_key?(:'documentDate') self.document_date = attributes[:'documentDate'] end if attributes.has_key?(:'glClass') self.gl_class = attributes[:'glClass'] end if attributes.has_key?(:'glTypeId') self.gl_type_id = attributes[:'glTypeId'] end if attributes.has_key?(:'glItemId') self.gl_item_id = attributes[:'glItemId'] end if attributes.has_key?(:'salesCode') self.sales_code = attributes[:'salesCode'] end if attributes.has_key?(:'description') self.description = attributes[:'description'] end if attributes.has_key?(:'cost') self.cost = attributes[:'cost'] end if attributes.has_key?(:'memo') self.memo = attributes[:'memo'] end if attributes.has_key?(:'taxNote') self.tax_note = attributes[:'taxNote'] end if attributes.has_key?(:'vendorNumber') self.vendor_number = attributes[:'vendorNumber'] end if attributes.has_key?(:'accountNumber') self.account_number = attributes[:'accountNumber'] end if attributes.has_key?(:'costAccountNumber') self.cost_account_number = attributes[:'costAccountNumber'] end if attributes.has_key?(:'inventoryAccountNumber') self.inventory_account_number = attributes[:'inventoryAccountNumber'] end if attributes.has_key?(:'vendorAccountNumber') self.vendor_account_number = attributes[:'vendorAccountNumber'] end if attributes.has_key?(:'item') self.item = attributes[:'item'] end if attributes.has_key?(:'itemDescription') self.item_description = attributes[:'itemDescription'] end if attributes.has_key?(:'salesDescription') self.sales_description = attributes[:'salesDescription'] end if attributes.has_key?(:'taxable') self.taxable = attributes[:'taxable'] end if attributes.has_key?(:'itemPrice') self.item_price = attributes[:'itemPrice'] end if attributes.has_key?(:'itemCost') self.item_cost = attributes[:'itemCost'] end if attributes.has_key?(:'unitOfMeasure') self.unit_of_measure = attributes[:'unitOfMeasure'] end if attributes.has_key?(:'quantity') self.quantity = attributes[:'quantity'] end if attributes.has_key?(:'total') self.total = attributes[:'total'] end if attributes.has_key?(:'currency') self.currency = attributes[:'currency'] end if attributes.has_key?(:'serializedFlag') self.serialized_flag = attributes[:'serializedFlag'] end if attributes.has_key?(:'serialNumbers') self.serial_numbers = attributes[:'serialNumbers'] end if attributes.has_key?(:'dropShippedFlag') self.drop_shipped_flag = attributes[:'dropShippedFlag'] end if attributes.has_key?(:'lineNumber') self.line_number = attributes[:'lineNumber'] end if attributes.has_key?(:'warehouseBin') self.warehouse_bin = attributes[:'warehouseBin'] end if attributes.has_key?(:'warehouseSite') self.warehouse_site = attributes[:'warehouseSite'] end if attributes.has_key?(:'subCategory') self.sub_category = attributes[:'subCategory'] end if attributes.has_key?(:'shipmentMethod') self.shipment_method = attributes[:'shipmentMethod'] end if attributes.has_key?(:'itemTypeXref') self.item_type_xref = attributes[:'itemTypeXref'] end if attributes.has_key?(:'inventoryXref') self.inventory_xref = attributes[:'inventoryXref'] end if attributes.has_key?(:'cogsXref') self.cogs_xref = attributes[:'cogsXref'] end if attributes.has_key?(:'uomScheduleXref') self.uom_schedule_xref = attributes[:'uomScheduleXref'] end if attributes.has_key?(:'priceLevelXref') self.price_level_xref = attributes[:'priceLevelXref'] end if attributes.has_key?(:'locationXref') self.location_xref = attributes[:'locationXref'] end if attributes.has_key?(:'taxCode') self.tax_code = attributes[:'taxCode'] end if attributes.has_key?(:'purchaseHeaderTaxGroup') self.purchase_header_tax_group = attributes[:'purchaseHeaderTaxGroup'] end if attributes.has_key?(:'taxCodeXref') self.tax_code_xref = attributes[:'taxCodeXref'] end if attributes.has_key?(:'taxRate') self.tax_rate = attributes[:'taxRate'] end if attributes.has_key?(:'taxAgencyXref') self.tax_agency_xref = attributes[:'taxAgencyXref'] end end |
Instance Attribute Details
#account_number ⇒ Object
Returns the value of attribute account_number.
29 30 31 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 29 def account_number @account_number end |
#cogs_xref ⇒ Object
Returns the value of attribute cogs_xref.
77 78 79 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 77 def cogs_xref @cogs_xref end |
#cost ⇒ Object
Returns the value of attribute cost.
21 22 23 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 21 def cost @cost end |
#cost_account_number ⇒ Object
Returns the value of attribute cost_account_number.
31 32 33 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 31 def cost_account_number @cost_account_number end |
#currency ⇒ Object
Returns the value of attribute currency.
55 56 57 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 55 def currency @currency end |
#description ⇒ Object
Returns the value of attribute description.
19 20 21 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 19 def description @description end |
#document_date ⇒ Object
Returns the value of attribute document_date.
9 10 11 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 9 def document_date @document_date end |
#drop_shipped_flag ⇒ Object
Returns the value of attribute drop_shipped_flag.
61 62 63 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 61 def drop_shipped_flag @drop_shipped_flag end |
#gl_class ⇒ Object
Returns the value of attribute gl_class.
11 12 13 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 11 def gl_class @gl_class end |
#gl_item_id ⇒ Object
Returns the value of attribute gl_item_id.
15 16 17 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 15 def gl_item_id @gl_item_id end |
#gl_type_id ⇒ Object
Returns the value of attribute gl_type_id.
13 14 15 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 13 def gl_type_id @gl_type_id end |
#id ⇒ Object
Returns the value of attribute id.
7 8 9 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 7 def id @id end |
#inventory_account_number ⇒ Object
Returns the value of attribute inventory_account_number.
33 34 35 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 33 def inventory_account_number @inventory_account_number end |
#inventory_xref ⇒ Object
Returns the value of attribute inventory_xref.
75 76 77 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 75 def inventory_xref @inventory_xref end |
#item ⇒ Object
Returns the value of attribute item.
37 38 39 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 37 def item @item end |
#item_cost ⇒ Object
Returns the value of attribute item_cost.
47 48 49 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 47 def item_cost @item_cost end |
#item_description ⇒ Object
Returns the value of attribute item_description.
39 40 41 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 39 def item_description @item_description end |
#item_price ⇒ Object
Returns the value of attribute item_price.
45 46 47 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 45 def item_price @item_price end |
#item_type_xref ⇒ Object
Returns the value of attribute item_type_xref.
73 74 75 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 73 def item_type_xref @item_type_xref end |
#line_number ⇒ Object
Returns the value of attribute line_number.
63 64 65 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 63 def line_number @line_number end |
#location_xref ⇒ Object
Returns the value of attribute location_xref.
83 84 85 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 83 def location_xref @location_xref end |
#memo ⇒ Object
Returns the value of attribute memo.
23 24 25 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 23 def memo @memo end |
#price_level_xref ⇒ Object
Returns the value of attribute price_level_xref.
81 82 83 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 81 def price_level_xref @price_level_xref end |
#purchase_header_tax_group ⇒ Object
Returns the value of attribute purchase_header_tax_group.
87 88 89 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 87 def purchase_header_tax_group @purchase_header_tax_group end |
#quantity ⇒ Object
Returns the value of attribute quantity.
51 52 53 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 51 def quantity @quantity end |
#sales_code ⇒ Object
Returns the value of attribute sales_code.
17 18 19 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 17 def sales_code @sales_code end |
#sales_description ⇒ Object
Returns the value of attribute sales_description.
41 42 43 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 41 def sales_description @sales_description end |
#serial_numbers ⇒ Object
Returns the value of attribute serial_numbers.
59 60 61 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 59 def serial_numbers @serial_numbers end |
#serialized_flag ⇒ Object
Returns the value of attribute serialized_flag.
57 58 59 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 57 def serialized_flag @serialized_flag end |
#shipment_method ⇒ Object
Returns the value of attribute shipment_method.
71 72 73 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 71 def shipment_method @shipment_method end |
#sub_category ⇒ Object
Returns the value of attribute sub_category.
69 70 71 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 69 def sub_category @sub_category end |
#tax_agency_xref ⇒ Object
Returns the value of attribute tax_agency_xref.
93 94 95 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 93 def tax_agency_xref @tax_agency_xref end |
#tax_code ⇒ Object
Returns the value of attribute tax_code.
85 86 87 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 85 def tax_code @tax_code end |
#tax_code_xref ⇒ Object
Returns the value of attribute tax_code_xref.
89 90 91 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 89 def tax_code_xref @tax_code_xref end |
#tax_note ⇒ Object
Returns the value of attribute tax_note.
25 26 27 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 25 def tax_note @tax_note end |
#tax_rate ⇒ Object
Returns the value of attribute tax_rate.
91 92 93 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 91 def tax_rate @tax_rate end |
#taxable ⇒ Object
Returns the value of attribute taxable.
43 44 45 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 43 def taxable @taxable end |
#total ⇒ Object
Returns the value of attribute total.
53 54 55 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 53 def total @total end |
#unit_of_measure ⇒ Object
Returns the value of attribute unit_of_measure.
49 50 51 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 49 def unit_of_measure @unit_of_measure end |
#uom_schedule_xref ⇒ Object
Returns the value of attribute uom_schedule_xref.
79 80 81 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 79 def uom_schedule_xref @uom_schedule_xref end |
#vendor_account_number ⇒ Object
Returns the value of attribute vendor_account_number.
35 36 37 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 35 def vendor_account_number @vendor_account_number end |
#vendor_number ⇒ Object
Returns the value of attribute vendor_number.
27 28 29 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 27 def vendor_number @vendor_number end |
#warehouse_bin ⇒ Object
Returns the value of attribute warehouse_bin.
65 66 67 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 65 def warehouse_bin @warehouse_bin end |
#warehouse_site ⇒ Object
Returns the value of attribute warehouse_site.
67 68 69 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 67 def warehouse_site @warehouse_site end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 97 def self.attribute_map { :'id' => :'id', :'document_date' => :'documentDate', :'gl_class' => :'glClass', :'gl_type_id' => :'glTypeId', :'gl_item_id' => :'glItemId', :'sales_code' => :'salesCode', :'description' => :'description', :'cost' => :'cost', :'memo' => :'memo', :'tax_note' => :'taxNote', :'vendor_number' => :'vendorNumber', :'account_number' => :'accountNumber', :'cost_account_number' => :'costAccountNumber', :'inventory_account_number' => :'inventoryAccountNumber', :'vendor_account_number' => :'vendorAccountNumber', :'item' => :'item', :'item_description' => :'itemDescription', :'sales_description' => :'salesDescription', :'taxable' => :'taxable', :'item_price' => :'itemPrice', :'item_cost' => :'itemCost', :'unit_of_measure' => :'unitOfMeasure', :'quantity' => :'quantity', :'total' => :'total', :'currency' => :'currency', :'serialized_flag' => :'serializedFlag', :'serial_numbers' => :'serialNumbers', :'drop_shipped_flag' => :'dropShippedFlag', :'line_number' => :'lineNumber', :'warehouse_bin' => :'warehouseBin', :'warehouse_site' => :'warehouseSite', :'sub_category' => :'subCategory', :'shipment_method' => :'shipmentMethod', :'item_type_xref' => :'itemTypeXref', :'inventory_xref' => :'inventoryXref', :'cogs_xref' => :'cogsXref', :'uom_schedule_xref' => :'uomScheduleXref', :'price_level_xref' => :'priceLevelXref', :'location_xref' => :'locationXref', :'tax_code' => :'taxCode', :'purchase_header_tax_group' => :'purchaseHeaderTaxGroup', :'tax_code_xref' => :'taxCodeXref', :'tax_rate' => :'taxRate', :'tax_agency_xref' => :'taxAgencyXref' } end |
.swagger_types ⇒ Object
Attribute type mapping.
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 147 def self.swagger_types { :'id' => :'Integer', :'document_date' => :'DateTime', :'gl_class' => :'String', :'gl_type_id' => :'String', :'gl_item_id' => :'String', :'sales_code' => :'String', :'description' => :'String', :'cost' => :'Float', :'memo' => :'String', :'tax_note' => :'String', :'vendor_number' => :'String', :'account_number' => :'String', :'cost_account_number' => :'String', :'inventory_account_number' => :'String', :'vendor_account_number' => :'String', :'item' => :'IvItemReference', :'item_description' => :'String', :'sales_description' => :'String', :'taxable' => :'BOOLEAN', :'item_price' => :'Float', :'item_cost' => :'Float', :'unit_of_measure' => :'UnitOfMeasureReference', :'quantity' => :'Float', :'total' => :'Float', :'currency' => :'CurrencyReference', :'serialized_flag' => :'BOOLEAN', :'serial_numbers' => :'String', :'drop_shipped_flag' => :'BOOLEAN', :'line_number' => :'Integer', :'warehouse_bin' => :'WarehouseBinReference', :'warehouse_site' => :'SiteReference', :'sub_category' => :'ProductSubCategoryReference', :'shipment_method' => :'ShipmentMethodReference', :'item_type_xref' => :'String', :'inventory_xref' => :'String', :'cogs_xref' => :'String', :'uom_schedule_xref' => :'String', :'price_level_xref' => :'String', :'location_xref' => :'String', :'tax_code' => :'TaxCodeReference', :'purchase_header_tax_group' => :'String', :'tax_code_xref' => :'String', :'tax_rate' => :'Float', :'tax_agency_xref' => :'String' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 397 def ==(o) return true if self.equal?(o) self.class == o.class && id == o.id && document_date == o.document_date && gl_class == o.gl_class && gl_type_id == o.gl_type_id && gl_item_id == o.gl_item_id && sales_code == o.sales_code && description == o.description && cost == o.cost && memo == o.memo && tax_note == o.tax_note && vendor_number == o.vendor_number && account_number == o.account_number && cost_account_number == o.cost_account_number && inventory_account_number == o.inventory_account_number && vendor_account_number == o.vendor_account_number && item == o.item && item_description == o.item_description && sales_description == o.sales_description && taxable == o.taxable && item_price == o.item_price && item_cost == o.item_cost && unit_of_measure == o.unit_of_measure && quantity == o.quantity && total == o.total && currency == o.currency && serialized_flag == o.serialized_flag && serial_numbers == o.serial_numbers && drop_shipped_flag == o.drop_shipped_flag && line_number == o.line_number && warehouse_bin == o.warehouse_bin && warehouse_site == o.warehouse_site && sub_category == o.sub_category && shipment_method == o.shipment_method && item_type_xref == o.item_type_xref && inventory_xref == o.inventory_xref && cogs_xref == o.cogs_xref && uom_schedule_xref == o.uom_schedule_xref && price_level_xref == o.price_level_xref && location_xref == o.location_xref && tax_code == o.tax_code && purchase_header_tax_group == o.purchase_header_tax_group && tax_code_xref == o.tax_code_xref && tax_rate == o.tax_rate && tax_agency_xref == o.tax_agency_xref end |
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type
482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 482 def _deserialize(type, value) case type.to_sym when :DateTime DateTime.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :BOOLEAN if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model temp_model = ConnectWise.const_get(type).new temp_model.build_from_hash(value) end end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
548 549 550 551 552 553 554 555 556 557 558 559 560 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 548 def _to_hash(value) if value.is_a?(Array) value.compact.map{ |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 461 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(o) ⇒ Boolean
448 449 450 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 448 def eql?(o) self == o end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
454 455 456 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 454 def hash [id, document_date, gl_class, gl_type_id, gl_item_id, sales_code, description, cost, memo, tax_note, vendor_number, account_number, cost_account_number, inventory_account_number, vendor_account_number, item, item_description, sales_description, taxable, item_price, item_cost, unit_of_measure, quantity, total, currency, serialized_flag, serial_numbers, drop_shipped_flag, line_number, warehouse_bin, warehouse_site, sub_category, shipment_method, item_type_xref, inventory_xref, cogs_xref, uom_schedule_xref, price_level_xref, location_xref, tax_code, purchase_header_tax_group, tax_code_xref, tax_rate, tax_agency_xref].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
384 385 386 387 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 384 def list_invalid_properties invalid_properties = Array.new return invalid_properties end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
528 529 530 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 528 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
534 535 536 537 538 539 540 541 542 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 534 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) next if value.nil? hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
522 523 524 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 522 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
391 392 393 |
# File 'lib/connectwise-ruby-sdk/models/gl_export_purchase_transaction_detail.rb', line 391 def valid? return true end |