Replace references to 'standing order' with 'subscription'

This commit is contained in:
Rob Harrington
2018-02-02 16:17:14 +11:00
parent 902802594f
commit 672f96b85b
24 changed files with 139 additions and 139 deletions

View File

@@ -8,7 +8,7 @@ module Api
if object.total.present?
object.total.to_money.to_s
else
object.standing_order.standing_line_items.sum(&:total_estimate)
object.subscription.standing_line_items.sum(&:total_estimate)
end
end

View File

@@ -1,6 +1,6 @@
module Api
module Admin
class StandingOrderSerializer < ActiveModel::Serializer
class SubscriptionSerializer < ActiveModel::Serializer
attributes :id, :shop_id, :customer_id, :schedule_id, :payment_method_id, :shipping_method_id, :begins_at, :ends_at
attributes :customer_email, :schedule_name, :edit_path, :canceled_at, :paused_at, :state, :credit_card_id
@@ -36,7 +36,7 @@ module Api
def edit_path
return '' unless object.id
edit_admin_standing_order_path(object)
edit_admin_subscription_path(object)
end
end
end