Files
Odoo-18.0-20251222/account_invoice_refund_link/wizards/account_move_reversal.py
tocmo0nlord adbe430761
Some checks failed
pre-commit / pre-commit (push) Has been cancelled
tests / Detect unreleased dependencies (push) Has been cancelled
tests / test with OCB (push) Has been cancelled
tests / test with Odoo (push) Has been cancelled
Initial commit: Odoo 18.0-20251222 extra-addons
2026-03-13 20:43:25 +00:00

18 lines
562 B
Python

# Copyright 2020 Tecnativa - Sergio Teruel
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import models
class AccountMoveReversal(models.TransientModel):
_inherit = "account.move.reversal"
def reverse_moves(self, is_modify=False):
"""
Only link invoice lines with theirs original lines when the reversal
move has been done from reversal wizard.
"""
return super(
AccountMoveReversal, self.with_context(link_origin_line=True)
).reverse_moves(is_modify=is_modify)