コンテンツへスキップ
メニュー
この質問にフラグが付けられました

I'm trying to inherit res.partner
and i'm trying to add new fields to my res.partner but error occur
This is the code:

from odoo import models , fields,api,_

class ResPartner(models.Model):
_inherit='res.partner'
is_student=fields.Boolean(string="Is Student?")
birth_date=fields.Date(string="Birth Date")
This is the error:

psycopg2.errors.UndefinedColumn: column res_partner.is_student does not exist

LINE 1: ...uid", "res_partner"."write_date" AS "write_date", "res_partn...








アバター
破棄
最善の回答

When you modify 'res.partner' or 'res.users' model you need to update your module using command line:
odoo-bin -d my_db -u my_module_name

アバター
破棄
関連投稿 返信 ビュー 活動
3
4月 23
4703
1
5月 25
2659
3
5月 24
2250
2
4月 24
2060
3
11月 24
4366