Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added ofx module, functions to generate ofx file from json data. #1

Draft
wants to merge 15 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions TODO.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
- [done] eliminam header, folosesc builder
- [done] sa folosesc API de date si time in js - https://date-fns.org/docs/Getting-Started
- [done] details -> MEMO
- [done] referinta la REFNUM ( cand exista)
- [done] informatii despre PAYEE
- [done] de scos FITID ( x-data si nr tranzactiei)

- fctie de dispatch pt conversie tranzactii in xml:
- Cumparare POS
- Taxe si comisioane
- Comision
- Plata debit direct
- Actualizare dobanda - configuratie manuala
- Incasare
- Comision pe operatiune
- Retragere numerar
- pentru tip necunoscut, arunca exceptie cu titlul
5,497 changes: 2,625 additions & 2,872 deletions package-lock.json

Large diffs are not rendered by default.

12 changes: 8 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,23 @@
"version": "0.1.0",
"private": true,
"homepage": "https://netdava.github.io/transaction-selector/",
"type": "module",
"dependencies": {
"@atlaskit/css-reset": "^5.0.10",
"@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.5.0",
"@testing-library/user-event": "^7.2.1",
"date-fns": "^2.12.0",
"lodash": "^4.17.15",
"blueimp-md5": "^2.18.0",
"currency.js": "^2.0.3",
"date-fns": "^2.15.0",
"lodash": "^4.17.20",
"papaparse": "^5.2.0",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-dropzone": "^10.2.2",
"react-scripts": "3.4.1",
"styled-components": "^5.0.1"
"react-scripts": "^3.4.3",
"styled-components": "^5.0.1",
"xmlbuilder2": "^2.3.1"
},
"scripts": {
"start": "react-scripts start",
Expand Down
315 changes: 315 additions & 0 deletions src/data/samples/sample.ofx
Original file line number Diff line number Diff line change
@@ -0,0 +1,315 @@


OFXHEADER:100
DATA:OFXSGML
VERSION:102
SECURITY:NONE
ENCODING:USASCII
CHARSET:1252
COMPRESSION:NONE
OLDFILEUID:NONE
NEWFILEUID:NONE

<OFX>
<SIGNONMSGSRSV1>
<SONRS>
<STATUS>
<CODE>0
<SEVERITY>INFO
</STATUS>
<DTSERVER>20091101192253
<LANGUAGE>POR
</SONRS>
</SIGNONMSGSRSV1>
<BANKMSGSRSV1>
<STMTTRNRS>
<TRNUID>1
<STATUS>
<CODE>0
<SEVERITY>INFO
</STATUS>
<STMTRS>
<CURDEF>BRL
<BANKACCTFROM>
<BANKID>0356
<ACCTID>03227113109
<ACCTTYPE>CHECKING
</BANKACCTFROM>
<BANKTRANLIST>
<DTSTART>20091009080000
<DTEND>20091103080000
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091009080000
<DTUSER>20090909080000
<TRNAMT>-35.34
<FITID>200910091
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
<SIC>5072
</STMTTRN><STMTTRN>
<TRNTYPE>CREDIT
<DTPOSTED>20091016080000
<DTUSER>20090916080000
<TRNAMT>60.39
<FITID>200910162
<CHECKNUM>0880136
<MEMO>DEPOSITO POUP.CORRENTE
</STMTTRN>
<STMTTRN>
<TRNTYPE>OTHER</TRNTYPE>
<DTPOSTED>20091019120000[-3:BRT]</DTPOSTED>
<DTUSER>20091017120000[-3:BRT]</DTPOSTED>
<TRNAMT>-148.40</TRNAMT>
<FITID>200910191148400</FITID>
<CHECKNUM>000000101901</CHECKNUM>
<REFNUM>101.901</REFNUM>
<PAYEE>Pagto conta telefone</PAYEE>
<MEMO>Pagto conta telefone</MEMO>
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-126.13
<FITID>200910131
<CHECKNUM>0001511
<NAME>Pagto conta telefone</NAME>
<MEMO>TITULO COBRANCA-IB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-232.23
<FITID>200910132
<CHECKNUM>0001511
<MEMO>TITULO COBRANCA-IB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-501.24
<FITID>200910133
<CHECKNUM>0001511
<MEMO>TITULO COBRANCA-IB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-719.03
<FITID>200910134
<CHECKNUM>0001511
<MEMO>TITULO COBRANCA-IB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-90.75
<FITID>200910135
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-49.80
<FITID>200910136
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-219.90
<FITID>200910137
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-54.61
<FITID>200910138
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-38.57
<FITID>200910139
<CHECKNUM>0002208
<MEMO>PAGTO CONTA TELEFONE -RIB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-119.40
<FITID>2009101310
<CHECKNUM>0002209
<MEMO>CONTA DE LUZ -RIB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-34.69
<FITID>2009101311
<CHECKNUM>0002208
<MEMO>PAGTO CONTA TELEFONE -RIB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-35.07
<FITID>2009101312
<CHECKNUM>0002231
<MEMO>IPTU / TAXAS SP -RIB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-259.10
<FITID>2009101313
<CHECKNUM>0001085
<MEMO>PGTO NET
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-202.84
<FITID>2009101314
<CHECKNUM>0002606
<MEMO>PARC RC EXCLUSIVO 12
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091013080000
<TRNAMT>-272.77
<FITID>2009101315
<CHECKNUM>0002606
<MEMO>PARC RC EXCLUSIVO 08
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091014080000
<TRNAMT>-80.00
<FITID>200910141
<CHECKNUM>0010991
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091014080000
<TRNAMT>-177.00
<FITID>200910142
<CHECKNUM>0010986
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091014080000
<TRNAMT>-386.00
<FITID>200910143
<CHECKNUM>0011063
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091014080000
<TRNAMT>-12.19
<FITID>200910144
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091015080000
<TRNAMT>-41.00
<FITID>200910151
<CHECKNUM>0011064
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091016080000
<TRNAMT>-63.00
<FITID>200910161
<CHECKNUM>0010856
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091019080000
<TRNAMT>-51.00
<FITID>200910191
<CHECKNUM>0011065
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091019080000
<TRNAMT>-23.81
<FITID>200910192
<CHECKNUM>0001203
<MEMO>ASSINATURA ABRIL
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091020080000
<TRNAMT>-15.50
<FITID>200910201
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091021080000
<TRNAMT>-132.00
<FITID>200910211
<CHECKNUM>0011023
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>CREDIT
<DTPOSTED>20091022080000
<TRNAMT>600.00
<FITID>200910221
<CHECKNUM>0001433
<MEMO>DOC REM 216.397.168-66
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091022080000
<TRNAMT>-22.40
<FITID>200910222
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091022080000
<TRNAMT>-73.16
<FITID>200910223
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091023080000
<TRNAMT>-61.36
<FITID>200910231
<CHECKNUM>0000292
<MEMO>CONTA AGUA/ESGOTO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091026080000
<TRNAMT>-96.00
<FITID>200910261
<CHECKNUM>0002212
<MEMO>PAGTO FATURA REALVISA-RIB
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091030080000
<TRNAMT>-67.75
<FITID>200910301
<CHECKNUM>0011061
<MEMO>CHEQUE COMPENSADO
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091030080000
<TRNAMT>-25.88
<FITID>200910302
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN><STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20091103080000
<TRNAMT>-89.03
<FITID>200911031
<CHECKNUM>0001223
<MEMO>COMPRA VISA ELECTRON
</STMTTRN>
</BANKTRANLIST>
<LEDGERBAL>
<BALAMT>598.44
<DTASOF>20091101
</LEDGERBAL>
<AVAILBAL>
<BALAMT>1555.99</BALAMT>
<DTASOF>20091101</DTASOF>
</AVAILBAL>
</STMTRS>
</STMTTRNRS>
</BANKMSGSRSV1>
</OFX>
Loading