[MIG] web_widget_x2many_2d_matrix_example: Migration to 12.0.

This commit is contained in:
Anand Kansagra
2018-12-31 11:33:16 +05:30
parent 22441ad62f
commit 4aafcfa5a5
13 changed files with 76 additions and 64 deletions

View File

@@ -1 +1,2 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from . import x2m_demo

View File

@@ -1,8 +1,10 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo import models, api, fields
class X2MDemo(models.Model):
_name = 'x2m.demo'
_description = 'X2Many Demo'
name = fields.Char()
line_ids = fields.One2many('x2m.demo.line', 'demo_id')
@@ -24,6 +26,7 @@ class X2MDemo(models.Model):
class X2MDemoLine(models.Model):
_name = 'x2m.demo.line'
_description = 'X2Many Demo Line'
name = fields.Char()
demo_id = fields.Many2one('x2m.demo')