lib/tickethub/supplier/booking.rb in tickethub-0.3.38 vs lib/tickethub/supplier/booking.rb in tickethub-0.3.39
- old
+ new
@@ -13,10 +13,11 @@
require_relative 'product'
require_relative 'variant'
require_relative 'message'
require_relative 'purchase'
require_relative 'fee'
+ require_relative 'discount'
require_relative 'broadcast'
collection_method :broadcast do |params|
Supplier::Broadcast.call self.endpoint, begin
post(:broadcast, params)
@@ -27,17 +28,19 @@
collection :answers, Supplier::Answer
collection :messages, Supplier::Message
collection :purchases, Supplier::Purchase
collection :fees, Supplier::Fee
+ collection :discounts, Supplier::Discount
association :order, Supplier::Order
association :rate, Supplier::Rate
association :coupon, Supplier::Coupon
association :product, Supplier::Product
association :variant, Supplier::Variant
attribute :amount, type: :money
+ attribute :discount, type: :money
attribute :tax, type: :money
attribute :total, type: :money
attribute :currency, type: :currency
attribute :created_at, type: :datetime
\ No newline at end of file