Analytics accounts are no longer required when using a period with the type adjustment

This commit is contained in:
Sergi Carol 2017-07-07 10:50:58 +02:00
parent 9a8ee873c6
commit a93c3ee12d
2 changed files with 4 additions and 0 deletions

View File

@ -1,6 +1,8 @@
Version 3.4.1 - 2015-01-20
* Use auxiliar field internal_currency instead of redefine currency as a
persistent field
* Analytics accounts with a period with the type 'adjustment' are no longer
checked for required analytic accounts
Version 3.4.0 - 2014-11-03

View File

@ -155,6 +155,8 @@ class Move:
def post(cls, moves):
super(Move, cls).post(moves)
for move in moves:
if move.period.type == 'adjustment':
continue
for line in move.lines:
required_roots = list(line.account.analytic_required[:])
if not line.analytic_lines and line.account.analytic_required: