camt_parser 2.17.0 → 2.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/camt_parser/general/transaction.rb +16 -0
- data/lib/camt_parser/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 65159c9e17355d90b7a3de05def06771c26a634a16bf6a6b3c7c3fed4d0175de
|
4
|
+
data.tar.gz: d4fe464522603dcb074279bebd12b915a43d3f1cd366f33c48e24b4d91c5324b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e4501cfc93989d6889a607df03f17eb49da240348c2a2fee8ae8a0af3f70619ba00b8da18525e9501fcc9709d39767fd3737bde0eb6e4224782792b0b9aa4a9f
|
7
|
+
data.tar.gz: 33f48ff56fb46a51be30c538ad692e7a0ca8ba4b6a58087d9b657f333670cee823b5c9b47d4a56c0e2a090e4d0cb6c564493db09cbff07b88b0b6bc092034ca0
|
@@ -80,6 +80,18 @@ module CamtParser
|
|
80
80
|
@reference ||= xml_data.xpath('Refs/InstrId/text()').text
|
81
81
|
end
|
82
82
|
|
83
|
+
def original_currency_amount # May be missing
|
84
|
+
@original_currency_amount ||= CamtParser::Misc.to_amount(parse_original_currency_amount)
|
85
|
+
end
|
86
|
+
|
87
|
+
def original_currency # May be missing
|
88
|
+
@original_currency ||= xml_data.xpath('AmtDtls/InstdAmt/Amt/@Ccy').text
|
89
|
+
end
|
90
|
+
|
91
|
+
def exchange_rate # May be missing
|
92
|
+
@exchange_rate ||= xml_data.xpath('AmtDtls/TxAmt/CcyXchg/XchgRate/text()').text
|
93
|
+
end
|
94
|
+
|
83
95
|
def bank_reference # May be missing
|
84
96
|
@bank_reference ||= xml_data.xpath('Refs/AcctSvcrRef/text()').text
|
85
97
|
end
|
@@ -118,6 +130,10 @@ module CamtParser
|
|
118
130
|
|
119
131
|
private
|
120
132
|
|
133
|
+
def parse_original_currency_amount
|
134
|
+
xml_data.xpath('AmtDtls/InstdAmt/Amt/text()').text
|
135
|
+
end
|
136
|
+
|
121
137
|
def parse_amount
|
122
138
|
if xml_data.xpath('Amt').any?
|
123
139
|
xml_data.xpath('Amt/text()').text
|
data/lib/camt_parser/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: camt_parser
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.18.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tobias Schoknecht
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-01-
|
10
|
+
date: 2025-01-15 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: rake
|