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

 Version 9

The code IND is used in 2 models:

<record id="ind" model="hc.vs.participation.type">   

            <field name="code">IND</field>

 

<record id="ind" model="hc.vs.identifier.type">

            <field name="code">IND</field>


Each model has the SQL constraint

_sql_constraints = [

        ('code_unique',

        'UNIQUE(code)',

        "The concept code must be unique.")

        ]

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

The field in the models are not the problem. It's the record ID that is the problem. Both record ID's are "ind":

<record id="ind" .....

There in lies your problem.

 Are you loading XML data this way? Where is the rest of the code. We can help you out more if we can see the rest of it.

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
3
thg 8 24
15276
2
thg 6 23
4237
0
thg 10 17
2573
0
thg 3 15
3763
1
thg 3 15
7434