Files
contract/contract/models/contract_template_line.py
Thomas Binsfeld a3f1cba1d1 [REF] contract: Several things
[REF] use context_today instead of time in filters
[REF] Contract: split from analytic account
[REF] Contract Sale Invoicing: split from analytic account
[REF] Contract Sale Invoicing: update translations
[IMP] - Assert that the predecessor is available for new link at uncancel
[RMV] - remove usless changes
[RMV] - Remove usless field recurring_invoices
  after the total isolation between contract model and account analytic one.
  recurring_invoices which was used to mark analytic account as contract became usless
[IMP] - P3 syntax
[IMP] - use @openupgrade.migrate() and openupgrade.logged_query
[IMP] - drop transient table in migration script
2023-03-15 12:37:40 +01:00

25 lines
776 B
Python

# Copyright 2004-2010 OpenERP SA
# Copyright 2014 Angel Moya <angel.moya@domatix.com>
# Copyright 2015 Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2016-2018 Carlos Dauden <carlos.dauden@tecnativa.com>
# Copyright 2016-2017 LasLabs Inc.
# Copyright 2018 ACSONE SA/NV
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo import fields, models
class ContractTemplateLine(models.Model):
_name = 'contract.template.line'
_inherit = 'contract.abstract.contract.line'
_description = "Contract Template Line"
_order = "sequence,id"
contract_id = fields.Many2one(
string='Contract',
comodel_name='contract.template',
required=True,
ondelete='cascade',
oldname='analytic_account_id',
)