parent
de45880eb3
commit
352ab7c51b
|
@ -2598,7 +2598,7 @@ class account_account_template(osv.osv):
|
|||
children_acc_criteria = [('chart_template_id','=', chart_template_id)]
|
||||
if template.account_root_id.id:
|
||||
children_acc_criteria = ['|'] + children_acc_criteria + ['&',('parent_id','child_of', [template.account_root_id.id]),('chart_template_id','=', False)]
|
||||
children_acc_template = self.search(cr, uid, [('nocreate','!=',True)] + children_acc_criteria, order='id')
|
||||
children_acc_template = self.search(cr, uid, [('nocreate','!=',True)] + children_acc_criteria, order='id', context=context)
|
||||
for account_template in self.browse(cr, uid, children_acc_template, context=context):
|
||||
# skip the root of COA if it's not the main one
|
||||
if (template.account_root_id.id == account_template.id) and template.parent_id:
|
||||
|
|
Loading…
Reference in New Issue