Lock move table when closing period
issue11093 review395221002
This commit is contained in:
1 parent
f4e06cb568
commit
12c2bc14e7
1 file changed
+2
-1
@@ -302,8 +302,9 @@ class Period(Workflow, ModelSQL, ModelView):
|
||||
Account = pool.get('account.account')
|
||||
transaction = Transaction()
|
||||
|
||||
# Lock period to be sure no new period will be created in between.
|
||||
# Lock period and move to be sure no new record will be created
|
||||
JournalPeriod.lock()
|
||||
Move.lock()
|
||||
|
||||
for period in periods:
|
||||
with transaction.set_context(
|
||||
|
||||
Reference in new issue
Block a user