Public release from ruodoo-project: 19.0 - 2026-05-31 21:19:12 UTC
This commit is contained in:
@ -0,0 +1,12 @@
|
||||
from odoo import api, models
|
||||
|
||||
|
||||
class PartnerContractCustomer(models.Model):
|
||||
_name = "partner.contract.customer"
|
||||
_inherit = ["partner.contract.customer", "docx.template.mixin"]
|
||||
|
||||
@api.onchange("profile_id")
|
||||
def _onchange_profile_id_set_docx_template(self):
|
||||
for rec in self:
|
||||
if rec.profile_id and not rec.docx_template_id and rec.profile_id.docx_template_id:
|
||||
rec.docx_template_id = rec.profile_id.docx_template_id
|
||||
Reference in New Issue
Block a user