* FIX: Issue #37425 filling of field amount_main_currency for foreign money accounts
The parameter amount_main_currency (argument #13 of addline()) was previously
filled even when the bank account was already using the company main currency.
This caused the field amount_main_currency to be populated incorrectly for
transactions that were not foreign currency operations.
The logic has been updated so that amount_main_currency is only filled when the
transaction involves a foreign currency account. For accounts already using the
company main currency, the value is now left NULL as expected.
This aligns the behavior with the intended usage of addline() and prevents
incorrect data in bank transaction records.
(cherry picked from commit cdc36551d918a2fa49060223bd7bb008a9de3c1b)
* FIX: Issue #37425 filling of field amount_main_currency for foreign money accounts
transfer.php: PhanTypeMismatchArgument: Argument 4 ($amount) is price2num((-1 * (float)($amount[$n]))) of type string but \Account::addline() takes float defined at htdocs/compta/bank/class/account.class.php:611
CI-PULL-REQUEST / phan / Run phan
Check warning on line R189
Check warning:
transfer.php: PhanTypeMismatchArgument: Argument 13 ($amount_main_currency) is $amount_main_currency_from of type ?string but \Account::addline() takes ?float defined at htdocs/compta/bank/class/account.class.php:611
CI-PULL-REQUEST / phan / Run phan
(cherry picked from commit b8f222c3d9c71bf09f66ce33b920b284a7308cf7)
* declare dateo
(cherry picked from commit 1401f74969b9842df87cc390bb97d8d09d304c38)
* declare of variables before action script
(cherry picked from commit 2b07209935d87549fd9d9720e8c090127e766c4e)
* Fix(accounting): exportWinfic now supports parameter like other export methods
* Fix CI PULL REQUEST
---------
Co-authored-by: Zakaria Boushaba <z.boushaba@vold.africa>