Tryton - Issues

 

Issue8879

Title Total Amount on OFX statement is actually Start / End Balance
Priority bug Status resolved
Superseder Nosy List ced, dave, reviewbot, roundup-bot
Type behavior Components account_statement_ofx
Assigned To dave Keywords review
Reviews 262751002
View: 262751002

Created on 2019-11-29.12:57:53 by dave, last changed by roundup-bot.

Messages
New changeset c0ab803f498e by David Harper in branch '5.4':
Use ofx file data for statement total_amount and start/end balance
https://hg.tryton.org/modules/account_statement_ofx/rev/c0ab803f498e

New changeset 78e18eb36cec by David Harper in branch '5.2':
Use ofx file data for statement total_amount and start/end balance
https://hg.tryton.org/modules/account_statement_ofx/rev/78e18eb36cec

New changeset 5b45fcf631a9 by David Harper in branch '5.0':
Use ofx file data for statement total_amount and start/end balance
https://hg.tryton.org/modules/account_statement_ofx/rev/5b45fcf631a9
New changeset 8da471d76452 by C├ędric Krier in branch 'default':
Use ofx file data for statement total_amount and start/end balance
https://hg.tryton.org/tryton-env/rev/8da471d76452
New changeset 91468eba7c56 by David Harper in branch 'default':
Use ofx file data for statement total_amount and start/end balance
https://hg.tryton.org/modules/account_statement_ofx/rev/91468eba7c56
review262751002 updated at https://codereview.tryton.org/262751002/#ps268701002
New review262751002 at https://codereview.tryton.org/262751002/#ps272721002
msg54287 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-12-05.18:44:11
It seems OK if the computation is simple.
msg53808 (view) Author: [hidden] (dave) (Tryton committer) Date: 2019-12-03.18:16:02
I was only suggesting using data from the OFX file.

From what I can see the ofx.account.statement.balance (LEDGERBAL aggregate) is the "End Balance" for the account, so I was suggesting possibly using this from the file, and the calculated "Total Amount" (also from the file) to get the "Start Balance".
msg53737 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-11-29.13:39:59
I do not think the starte/end balance is an available information on OFX.
We should fill data only with the content of the file.
msg53735 (view) Author: [hidden] (dave) (Tryton committer) Date: 2019-11-29.13:36:15
Would it be sensible to add the "Start Balance" / "End Balance" using the ofx.account.statement.balance too?  As you cannot use an Validation Type of Balance with OFX files because the start / end balance are then required fields so the statement cannot be created without them, or is that a separate issue?
msg53734 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-11-29.13:22:59
It looks like OFX does not contain the total amount, so it should be computed.
msg53733 (view) Author: [hidden] (dave) (Tryton committer) Date: 2019-11-29.12:57:53
When importing an OFX statement, the Total Amount field is populated with the ofx.account.statement.balance.  This value is actually the account balance on the ofx.account.statement.balance_date, and not the sum of the values of the transactions on the statement.

Notes: The ofx.account.statement.balance field is taken from the BALAMT element inside the LEDGERBAL aggregate in the OFX file.  This is not the total of the transactions values as can be seen from the example on page 329 of the ofx spec (https://www.ofx.net/downloads/OFX%202.2.pdf).
History
Date User Action Args
2020-01-22 22:24:45roundup-botsetmessages: + msg55000
keyword: - backport
2020-01-10 17:03:45roundup-botsetmessages: + msg54803
2020-01-10 17:03:41roundup-botsetstatus: testing -> resolved
nosy: + roundup-bot
messages: + msg54802
2020-01-09 23:58:32reviewbotsetmessages: + msg54793
2020-01-09 23:07:21cedsetkeyword: + backport
2020-01-06 15:57:34reviewbotsetnosy: + reviewbot
messages: + msg54743
2020-01-06 15:57:33reviewbotsetreviews: 262751002
keyword: + review
2020-01-06 15:30:14davesetstatus: chatting -> testing
assignedto: dave
2019-12-05 18:44:11cedsetmessages: + msg54287
2019-12-03 18:16:02davesetmessages: + msg53808

Showing 10 items. Show all history (warning: this could be VERY long)