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

I tried adding a model constraint of type 'u' from Settings -> Database Structure -> Model constraints to res.partner's base module. But there was no way to specify column/field name to which the constraint should apply ?

I hope there is a way to add constraint without altering any Odoo code. 

Any suggestions ?

Ảnh đại diện
Huỷ bỏ

I think there is no option to add constraint from back end.

Tác giả

Will adding/updating ir.model.constraint work without creating any other issue ?

Câu trả lời hay nhất

Hi

To add this you must go to the code

It can not be increased by the user interface

because you deserve to restart the server odoo 

look this code 

https://stackoverflow.com/questions/31513326/what-is-the-correct-format-to-use-unique-in-sql-constraints-in-openerp

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
4
thg 3 15
11894
1
thg 3 15
7756
2
thg 8 25
3103
1
thg 2 22
3640
1
thg 11 24
19995