Initial commit: Accounting packages

This commit is contained in:
Ernad Husremovic 2025-08-29 15:20:47 +02:00
commit 4ef34c2317
2661 changed files with 1709616 additions and 0 deletions

View file

@ -0,0 +1,26 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import models
class PaymentLinkWizard(models.TransientModel):
_inherit = 'payment.link.wizard'
def _get_additional_link_values(self):
""" Override of `payment` to add `invoice_id` to the payment link values.
The other values related to the invoice are directly read from the invoice.
Note: self.ensure_one()
:return: The additional payment link values.
:rtype: dict
"""
res = super()._get_additional_link_values()
if self.res_model != 'account.move':
return res
# Invoice-related fields are retrieved in the controller.
return {
'invoice_id': self.res_id,
}