Class: Externals::Omise::Customer
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Externals::Omise::Customer
- Defined in:
- app/models/externals/omise/customer.rb
Overview
typed: ignore frozen_string_literal: true
Instance Method Summary collapse
-
#charged_amount(charged_reservation) ⇒ Object
validates :reservation, presence: true.
Methods inherited from ApplicationRecord
Instance Method Details
#charged_amount(charged_reservation) ⇒ Object
validates :reservation, presence: true
17 18 19 |
# File 'app/models/externals/omise/customer.rb', line 17 def charged_amount(charged_reservation) charges.where(reservation: charged_reservation).map(&:amount).sum end |