Class: Dolibarr::Payment
Overview
A payment recorded against an invoice. The amount is BigDecimal; the rest of the
Dolibarr payload stays reachable via Record#raw / Record#[].
Instance Attribute Summary
Attributes inherited from Record
Instance Method Summary collapse
-
#amount ⇒ BigDecimal?
The paid amount.
-
#date ⇒ String?
The payment date as returned by Dolibarr.
-
#ref ⇒ String?
The payment reference, when present.
-
#type ⇒ String?
The payment mode label/code (e.g. "VIR", "CHQ").
Methods inherited from Record
#==, #[], from, #hash, #id, #initialize, #to_h
Constructor Details
This class inherits a constructor from Dolibarr::Record
Instance Method Details
#amount ⇒ BigDecimal?
Returns the paid amount.
8 9 10 |
# File 'lib/dolibarr/payment.rb', line 8 def amount self['amount'] end |
#date ⇒ String?
Returns the payment date as returned by Dolibarr.
18 19 20 |
# File 'lib/dolibarr/payment.rb', line 18 def date self['date'] end |
#ref ⇒ String?
Returns the payment reference, when present.
23 24 25 |
# File 'lib/dolibarr/payment.rb', line 23 def ref self['ref'] end |
#type ⇒ String?
Returns the payment mode label/code (e.g. "VIR", "CHQ").
13 14 15 |
# File 'lib/dolibarr/payment.rb', line 13 def type self['type'] end |