[IMP] account: add inverse of reversed_entry_id

We often have to know if an entry is reversed (i.e. if it has a reversal
move_id), not if this is the move that is the reversal of another move.
This commit is contained in:
william
2020-05-25 08:30:12 +00:00
parent 8eefb69252
commit 09a6a4da11
+1
View File
@@ -224,6 +224,7 @@ class AccountMove(models.Model):
# ==== Reverse feature fields ====
reversed_entry_id = fields.Many2one('account.move', string="Reversal of", readonly=True, copy=False,
check_company=True)
reversal_move_id = fields.One2many('account.move', 'reversed_entry_id')
# =========================================================
# Invoice related fields