跳至内容
菜单
此问题已终结
1 回复
4509 查看

Odoo13 - odoo.sh


I have a custom model made via the UI, called x_custom_thing.

I want to extend that like so:

class XCustomThing(models.Model):
    _inherit = "x_custom_thing"
    
    company_id = fields.Many2one('res.company', 'Company', index=1)
    vendor_id = fields.Many2one('res.company', 'Vendor', index=1)

I get the error that

"TypeError: Model 'x_custom_thing' does not exist in registry".

How do I inherit and extend a custom model made via the UI? Can I?


形象
丢弃
最佳答案

Install this module

x_custom_thing

and this problem will fixed. Such kind of the errors

"TypeError: Model 'x_custom_thing' does not exist in registry".

appear once inherit module not installed.
形象
丢弃
编写者

And how can I inherit the model x_custom_thing and add fields? That still doesn't work.

相关帖文 回复 查看 活动
1
2月 23
2490
0
7月 19
3068
2
9月 20
8615
0
12月 19
4088
1
4月 24
9468