I have overridden a method to append some new items to the dictionary of the original method. when I execute my code I have this error:
'bool' object has no attribute 'dict_one'
but the original method has that attribute here is my code:
def action_transaction_done(self):
res = super(ProjectTransaction, self).action_transaction_done()
res.dict_one['branch_id'] = self.branch_id.id
return res
and this the orginal method code:
def action_transaction_done(self):
for action in self:
for line in action.details_by_category:
if self.account_id:
dict_one= (0, 0, {
'name': line.name,
'partner_id': line._get_partner_id(credit_account=False),
'account_id': self.account_id,
'journal_id': action.journal_id.id,
'date': date,
#to be added here
})
return dict_one
I want to append this new item the dict