Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
2325 Lượt xem

with Odoo 14, I'm getting this error message


psycopg2.errors.SyntaxError: syntax error at or near ")"
LINE 11:             WHERE U.partner_id IN () AND U.active = 't'


when trying to create a model that extends res.partner, like this


class ModelName(models.Model):
_inherits = {'res.partner' : 'partner_id'}
_name = 'someName'
_description = 'SomeDescription'

partner_id = fields.Many2one(
'res.partner',
ondelete='cascade'
)

 birthDate = fields.Date(string="Birth Date")
 place_of_birth = fields.Char(string="Place of Birth")


what's wrong with my extension ?

Ảnh đại diện
Huỷ bỏ
Tác giả Câu trả lời hay nhất

Thank you 20pmerikgen


I think I understand the difference between "_inherit" and "_inherits", that was just an example

I found the problem. I just forgot to give my model a form view, that's all

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 12 23
1165
0
thg 9 23
1864
1
thg 6 22
10389
1
thg 1 17
4421
1
thg 7 24
4623