You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
570 B

  1. # Copyright (C) 2018 - TODAY, Open Source Integrators
  2. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
  3. from odoo import fields, models
  4. class ProjectProject(models.Model):
  5. _inherit = "project.project"
  6. agreement_id = fields.Many2one('agreement', 'Agreement')
  7. class ProjectTask(models.Model):
  8. _inherit = "project.task"
  9. agreement_id = fields.Many2one('agreement',
  10. related="project_id.agreement_id",
  11. string='Agreement',
  12. store=True)