Class: Spree::ReimbursementPerformer
- Inherits:
-
Object
- Object
- Spree::ReimbursementPerformer
- Defined in:
- app/models/spree/reimbursement_performer.rb
Class Method Summary collapse
-
.perform(reimbursement) ⇒ Object
Actually perform the reimbursement.
-
.simulate(reimbursement) ⇒ Object
Simulate performing the reimbursement without actually saving anything or refunding money, etc.
Class Method Details
.perform(reimbursement) ⇒ Object
Actually perform the reimbursement
17 18 19 |
# File 'app/models/spree/reimbursement_performer.rb', line 17 def perform(reimbursement) execute(reimbursement, false) end |
.simulate(reimbursement) ⇒ Object
Simulate performing the reimbursement without actually saving anything or refunding money, etc. This must return an array of objects that respond to the following methods:
-
#description
-
#display_amount
so they can be displayed in the Admin UI appropriately.
12 13 14 |
# File 'app/models/spree/reimbursement_performer.rb', line 12 def simulate(reimbursement) execute(reimbursement, true) end |