Class: ChargeBee::Order

Inherits:
Model
  • Object
show all
Defined in:
lib/chargebee/models/order.rb

Defined Under Namespace

Classes: BillingAddress, LineItemDiscount, LineItemTax, LinkedCreditNote, OrderLineItem, ShippingAddress

Instance Attribute Summary collapse

Class Method Summary collapse

Methods inherited from Model

construct, #init_dependant, #init_dependant_list, #initialize, #inspect, #load, #method_missing, #to_s, uri_path

Constructor Details

This class inherits a constructor from ChargeBee::Model

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class ChargeBee::Model

Instance Attribute Details

#amount_adjustedObject

Returns the value of attribute amount_adjusted.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def amount_adjusted
  @amount_adjusted
end

#amount_paidObject

Returns the value of attribute amount_paid.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def amount_paid
  @amount_paid
end

#batch_idObject

Returns the value of attribute batch_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def batch_id
  @batch_id
end

#billing_addressObject

Returns the value of attribute billing_address.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def billing_address
  @billing_address
end

#cancellation_reasonObject

Returns the value of attribute cancellation_reason.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def cancellation_reason
  @cancellation_reason
end

#cancelled_atObject

Returns the value of attribute cancelled_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def cancelled_at
  @cancelled_at
end

#created_atObject

Returns the value of attribute created_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def created_at
  @created_at
end

#created_byObject

Returns the value of attribute created_by.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def created_by
  @created_by
end

#currency_codeObject

Returns the value of attribute currency_code.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def currency_code
  @currency_code
end

#customer_idObject

Returns the value of attribute customer_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def customer_id
  @customer_id
end

#deletedObject

Returns the value of attribute deleted.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def deleted
  @deleted
end

#delivered_atObject

Returns the value of attribute delivered_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def delivered_at
  @delivered_at
end

#discountObject

Returns the value of attribute discount.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def discount
  @discount
end

#document_numberObject

Returns the value of attribute document_number.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def document_number
  @document_number
end

#fulfillment_statusObject

Returns the value of attribute fulfillment_status.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def fulfillment_status
  @fulfillment_status
end

#gift_idObject

Returns the value of attribute gift_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def gift_id
  @gift_id
end

#gift_noteObject

Returns the value of attribute gift_note.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def gift_note
  @gift_note
end

#idObject

Returns the value of attribute id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def id
  @id
end

#invoice_idObject

Returns the value of attribute invoice_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def invoice_id
  @invoice_id
end

#invoice_round_off_amountObject

Returns the value of attribute invoice_round_off_amount.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def invoice_round_off_amount
  @invoice_round_off_amount
end

#is_giftedObject

Returns the value of attribute is_gifted.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def is_gifted
  @is_gifted
end

#line_item_discountsObject

Returns the value of attribute line_item_discounts.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def line_item_discounts
  @line_item_discounts
end

#line_item_taxesObject

Returns the value of attribute line_item_taxes.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def line_item_taxes
  @line_item_taxes
end

#linked_credit_notesObject

Returns the value of attribute linked_credit_notes.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def linked_credit_notes
  @linked_credit_notes
end

#noteObject

Returns the value of attribute note.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def note
  @note
end

#order_dateObject

Returns the value of attribute order_date.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def order_date
  @order_date
end

#order_line_itemsObject

Returns the value of attribute order_line_items.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def order_line_items
  @order_line_items
end

#order_typeObject

Returns the value of attribute order_type.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def order_type
  @order_type
end

Returns the value of attribute paid_on.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def paid_on
  @paid_on
end

#payment_statusObject

Returns the value of attribute payment_status.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def payment_status
  @payment_status
end

#price_typeObject

Returns the value of attribute price_type.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def price_type
  @price_type
end

#reference_idObject

Returns the value of attribute reference_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def reference_id
  @reference_id
end

#refundable_creditsObject

Returns the value of attribute refundable_credits.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def refundable_credits
  @refundable_credits
end

#refundable_credits_issuedObject

Returns the value of attribute refundable_credits_issued.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def refundable_credits_issued
  @refundable_credits_issued
end

#resource_versionObject

Returns the value of attribute resource_version.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def resource_version
  @resource_version
end

#rounding_adjustementObject

Returns the value of attribute rounding_adjustement.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def rounding_adjustement
  @rounding_adjustement
end

#shipment_carrierObject

Returns the value of attribute shipment_carrier.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def shipment_carrier
  @shipment_carrier
end

#shipped_atObject

Returns the value of attribute shipped_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def shipped_at
  @shipped_at
end

#shipping_addressObject

Returns the value of attribute shipping_address.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def shipping_address
  @shipping_address
end

#shipping_cut_off_dateObject

Returns the value of attribute shipping_cut_off_date.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def shipping_cut_off_date
  @shipping_cut_off_date
end

#shipping_dateObject

Returns the value of attribute shipping_date.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def shipping_date
  @shipping_date
end

#statusObject

Returns the value of attribute status.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def status
  @status
end

#status_update_atObject

Returns the value of attribute status_update_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def status_update_at
  @status_update_at
end

#sub_totalObject

Returns the value of attribute sub_total.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def sub_total
  @sub_total
end

#subscription_idObject

Returns the value of attribute subscription_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def subscription_id
  @subscription_id
end

#taxObject

Returns the value of attribute tax.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def tax
  @tax
end

#totalObject

Returns the value of attribute total.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def total
  @total
end

#tracking_idObject

Returns the value of attribute tracking_id.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def tracking_id
  @tracking_id
end

#updated_atObject

Returns the value of attribute updated_at.



28
29
30
# File 'lib/chargebee/models/order.rb', line 28

def updated_at
  @updated_at
end

Class Method Details

.assign_order_number(id, env = nil, headers = {}) ⇒ Object



52
53
54
# File 'lib/chargebee/models/order.rb', line 52

def self.assign_order_number(id, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s,"assign_order_number"), {}, env, headers)
end

.cancel(id, params, env = nil, headers = {}) ⇒ Object



56
57
58
# File 'lib/chargebee/models/order.rb', line 56

def self.cancel(id, params, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s,"cancel"), params, env, headers)
end

.create(params, env = nil, headers = {}) ⇒ Object

OPERATIONS




40
41
42
# File 'lib/chargebee/models/order.rb', line 40

def self.create(params, env=nil, headers={})
  Request.send('post', uri_path("orders"), params, env, headers)
end

.create_refundable_credit_note(id, params, env = nil, headers = {}) ⇒ Object



60
61
62
# File 'lib/chargebee/models/order.rb', line 60

def self.create_refundable_credit_note(id, params, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s,"create_refundable_credit_note"), params, env, headers)
end

.delete(id, env = nil, headers = {}) ⇒ Object



72
73
74
# File 'lib/chargebee/models/order.rb', line 72

def self.delete(id, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s,"delete"), {}, env, headers)
end

.import_order(params, env = nil, headers = {}) ⇒ Object



48
49
50
# File 'lib/chargebee/models/order.rb', line 48

def self.import_order(params, env=nil, headers={})
  Request.send('post', uri_path("orders","import_order"), params, env, headers)
end

.list(params = {}, env = nil, headers = {}) ⇒ Object



76
77
78
# File 'lib/chargebee/models/order.rb', line 76

def self.list(params={}, env=nil, headers={})
  Request.send_list_request('get', uri_path("orders"), params, env, headers)
end

.orders_for_invoice(id, params = {}, env = nil, headers = {}) ⇒ Object



80
81
82
# File 'lib/chargebee/models/order.rb', line 80

def self.orders_for_invoice(id, params={}, env=nil, headers={})
  Request.send('get', uri_path("invoices",id.to_s,"orders"), params, env, headers)
end

.reopen(id, params = {}, env = nil, headers = {}) ⇒ Object



64
65
66
# File 'lib/chargebee/models/order.rb', line 64

def self.reopen(id, params={}, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s,"reopen"), params, env, headers)
end

.retrieve(id, env = nil, headers = {}) ⇒ Object



68
69
70
# File 'lib/chargebee/models/order.rb', line 68

def self.retrieve(id, env=nil, headers={})
  Request.send('get', uri_path("orders",id.to_s), {}, env, headers)
end

.update(id, params = {}, env = nil, headers = {}) ⇒ Object



44
45
46
# File 'lib/chargebee/models/order.rb', line 44

def self.update(id, params={}, env=nil, headers={})
  Request.send('post', uri_path("orders",id.to_s), params, env, headers)
end