Cédric Krier pushed to branch branch/default at Tryton / Tryton
Commits:
d7c9a4c9 by Cédric Krier at 2023-07-17T23:05:11+02:00
Set next party after next account only on initial filling of accounts
When the next account method is called from the while loop, the next party is
always called by the upper loop.
If next party is called also in next account then the first party is skipped.
Closes #12327
- - - - -
1 changed file:
- modules/account/move.py
Changes:
=====================================
modules/account/move.py
=====================================
@@ -2145,7 +2145,6 @@
self.show.account = account
self.show.accounts = accounts
self.show.parties = self.get_parties(account)
- next_party()
return account
def next_party():
@@ -2170,7 +2169,7 @@
if getattr(self.show, 'accounts', None) is None:
self.show.accounts = self.get_accounts()
- if not next_account():
+ if not (next_account() and next_party()):
return 'end'
if getattr(self.show, 'parties', None) is None:
self.show.parties = self.get_parties(self.show.account)
View it on Heptapod:
https://foss.heptapod.net/tryton/tryton/-/commit/d7c9a4c976b6bbcf7e2a9740e5cb951b0d207d6a
--
View it on Heptapod:
https://foss.heptapod.net/tryton/tryton/-/commit/d7c9a4c976b6bbcf7e2a9740e5cb951b0d207d6a
You're receiving this email because of your account on foss.heptapod.net.