mirror of
https://github.com/ForgeFlow/stock-rma.git
synced 2025-01-21 12:57:49 +02:00
[9.0][REW] rma: workflow centralized on rma.order.line and the use of rma.order is optional.
This commit is contained in:
@@ -8,7 +8,10 @@ from openerp import api, fields, models
|
||||
class ProcurementOrder(models.Model):
|
||||
_inherit = 'procurement.order'
|
||||
|
||||
rma_line_id = fields.Many2one('rma.order.line', 'RMA', ondelete="set null")
|
||||
rma_line_id = fields.Many2one(
|
||||
comodel_name='rma.order.line', string='RMA line',
|
||||
ondelete="set null",
|
||||
)
|
||||
|
||||
@api.model
|
||||
def _run_move_create(self, procurement):
|
||||
@@ -26,4 +29,11 @@ class ProcurementOrder(models.Model):
|
||||
class ProcurementGroup(models.Model):
|
||||
_inherit = 'procurement.group'
|
||||
|
||||
rma_id = fields.Many2one('rma.order', 'RMA', ondelete="set null")
|
||||
rma_id = fields.Many2one(
|
||||
comodel_name='rma.order', string='RMA',
|
||||
ondelete="set null",
|
||||
)
|
||||
rma_line_id = fields.Many2one(
|
||||
comodel_name='rma.order.line', string='RMA line',
|
||||
ondelete="set null",
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user