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

Transaction <> Account #29

Open
grummbeer opened this issue Dec 11, 2023 · 4 comments
Open

Transaction <> Account #29

grummbeer opened this issue Dec 11, 2023 · 4 comments

Comments

@grummbeer
Copy link

Transaction should not convert local* and remote* values into an Account entity.

  1. Account is an AqBanking Account, with mandatory BLZ as bankCode, which is needed for requests.
  2. "Account" from Transaction is more like a "BankingContact" without any mandatory "BLZ", eg. bankCode is the BIC an accountNumber the IBAN
  3. The fetched fields depends on download mode. "CAMT" is different from "not CAMT"
  4. What is specified as "localName" in Transaction has nothing to do with the real local "Account" oder "User", it is what the other party (remote) has entered in the "Empfänger" field
  5. Some fields from a Transaction are omitted by parser, but should not, all fields should be there.

Possible solution:

  • construct the Transaction with a array of key,values from transaction xml or direct from xml content.
    • Transaction::fromXML('xml content')
    • Transaction::fromArray('array<key, value>')
    • new Transaction('array<key, value>')
    • or similar
  • use magic getters __get('key of transaction data')
  • Do not convert local* and remote* values to an (AqBanking) Account entity.
  • The true local* is provided by the accountInfo node
  • turning value into a Money Object by its getter. getValue() => return Money …
@amenk
Copy link
Member

amenk commented Dec 11, 2023

I am wondering if we should support not CAMT?

@grummbeer
Copy link
Author

No idea. :-) I'am not a banking/HBCI pro and do not know all the specs.

@grummbeer
Copy link
Author

Need time to try my own implementation in real life before doing anything here.

@grummbeer
Copy link
Author

Related to #22

The current state of inconsistency is proven by two failing tests.

  1. public function testCanRenderTransfers()
  2. public function testCanRenderTransactions()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants