Module: Buckaruby::TransactionStatus
- Defined in:
- lib/buckaruby/transaction_status.rb
Overview
Parses the transaction status code from Buckaroo.
Constant Summary collapse
- SUCCESS =
1
- FAILED =
2
- REJECTED =
3
- CANCELLED =
4
- PENDING =
5
Class Method Summary collapse
Class Method Details
.parse(brq_statuscode) ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/buckaruby/transaction_status.rb', line 15 def parse(brq_statuscode) case brq_statuscode when '190' TransactionStatus::SUCCESS when '490', '491', '492' TransactionStatus::FAILED when '690' TransactionStatus::REJECTED when '790', '791', '792', '793' TransactionStatus::PENDING when '890', '891' TransactionStatus::CANCELLED end end |