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.

18 lines
630 B

  1. # -*- coding: utf-8 -*-
  2. # Copyright 2014-2019 Therp BV <https://therp.nl>.
  3. # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
  4. from odoo import fields, models
  5. class ResPartner(models.Model):
  6. _inherit = 'res.partner'
  7. subscription_ids = fields.One2many(
  8. comodel_name='account.analytic.invoice.line',
  9. inverse_name='partner_id',
  10. domain=[('publication', '=', True)],
  11. string='Subscription contract lines')
  12. distribution_list_ids = fields.One2many(
  13. comodel_name='publication.distribution.list',
  14. inverse_name='partner_id',
  15. string='Publications received')