Methods
Attributes
| [R] | coupon | |
| [R] | plan | |
| [R] | plan_amount | |
| [R] | tax_percentage |
Class Public methods
call(*args) Link
Source: show
# File app/services/service/plan_amount_calculator.rb, line 6 def call(*args) new(*args).execute end
new(args = {}) Link
Source: show
# File app/services/service/plan_amount_calculator.rb, line 11 def initialize(args = {}) @plan = args.fetch(:plan) @coupon = args.fetch(:coupon, nil) @metadata = args.fetch(:metadata, {}) @plan_amount = plan.amount @tax_percentage = plan.tax_percentage end