mirror of
https://github.com/ForgeFlow/stock-rma.git
synced 2025-01-21 12:57:49 +02:00
17 lines
520 B
Python
17 lines
520 B
Python
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
|
# License LGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
|
|
|
|
from odoo import fields, models
|
|
|
|
|
|
class RepairOrder(models.Model):
|
|
_inherit = "repair.order"
|
|
|
|
rma_line_id = fields.Many2one(
|
|
comodel_name='rma.order.line', string='RMA', ondelete='restrict',
|
|
)
|
|
under_warranty = fields.Boolean(
|
|
related='rma_line_id.under_warranty', readonly=False,
|
|
)
|
|
invoice_status = fields.Selection(related='invoice_id.state')
|