Class: TheTracker::Trackers::EcommerceTransaction
- Inherits:
-
Struct
- Object
- Struct
- TheTracker::Trackers::EcommerceTransaction
- Defined in:
- lib/the_tracker/trackers/g_universal.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#shipping ⇒ Object
Returns the value of attribute shipping.
-
#store ⇒ Object
Returns the value of attribute store.
-
#tax ⇒ Object
Returns the value of attribute tax.
-
#total ⇒ Object
Returns the value of attribute total.
Instance Method Summary collapse
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id
116 117 118 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 116 def id @id end |
#shipping ⇒ Object
Returns the value of attribute shipping
116 117 118 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 116 def shipping @shipping end |
#store ⇒ Object
Returns the value of attribute store
116 117 118 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 116 def store @store end |
#tax ⇒ Object
Returns the value of attribute tax
116 117 118 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 116 def tax @tax end |
#total ⇒ Object
Returns the value of attribute total
116 117 118 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 116 def total @total end |
Instance Method Details
#add_item(sku, product, category, price, quantity) ⇒ Object
117 118 119 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 117 def add_item(sku, product, category, price, quantity) items << EcommerceItem.new(sku, product, category, price, quantity) end |
#items ⇒ Object
121 122 123 |
# File 'lib/the_tracker/trackers/g_universal.rb', line 121 def items @items ||= [] end |