Would like to ask any solutions for prevent duplicates in DB to format the API call?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- 会計
- 在庫
- PoS
- Project
- MRP
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Would like to ask any solutions for prevent duplicates in DB to format the API call?
Use SQL constraints on model
class PosOrder(models.Model):
_inherit = "pos.order"
_sql_constraints = [('name_uniq', 'unique (name)', "Order with this name already exists!"), ]
関連投稿 | 返信 | ビュー | 活動 | |
---|---|---|---|---|
|
3
4月 25
|
734 | ||
|
1
1月 25
|
1646 | ||
|
1
8月 24
|
1546 | ||
|
2
5月 24
|
1246 | ||
|
3
5月 24
|
10383 |