Overview
Comment: | Reconciled assist: Fix sign of numbers below 1 |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk | stable |
Files: | files | file ages | folders |
SHA1: |
93883c83562675ae9e93a7fced42bdf1 |
User & Date: | bohwaz on 2020-12-15 23:10:26 |
Other Links: | manifest | tags |
Context
2020-12-15
| ||
23:49 | Fix new transaction type from account shortcut check-in: 892e42cdd0 user: bohwaz tags: trunk, stable | |
23:10 | Reconciled assist: Fix sign of numbers below 1 check-in: 93883c8356 user: bohwaz tags: trunk, stable | |
23:07 | Assisted reconciliation: match sign of amount check-in: db6e1617a1 user: bohwaz tags: trunk, stable | |
Changes
Modified src/include/lib/Garradin/Entities/Accounting/Account.php from [d77b9e219e] to [129167ff5d].
︙ | ︙ | |||
291 292 293 294 295 296 297 | $journal = iterator_to_array($journal); $i = 0; $sum = 0; foreach ($csv as $k => &$line) { try { $date = \DateTime::createFromFormat('!d/m/Y', $line->date); | | | 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 | $journal = iterator_to_array($journal); $i = 0; $sum = 0; foreach ($csv as $k => &$line) { try { $date = \DateTime::createFromFormat('!d/m/Y', $line->date); $line->amount = (substr($line->amount, 0, 1) == '-' ? -1 : 1) * Utils::moneyToInteger($line->amount); if (!$date) { throw new UserException('Date invalide : ' . $line->date); } $line->date = $date; } |
︙ | ︙ |