[IMP] stock_location_orderpoint:

- Improve sql unique constraint
- Add priority field to tree view
This commit is contained in:
Michael Tietz
2023-07-17 21:46:11 +02:00
parent cf0e0b2372
commit 79e7bd3197
2 changed files with 3 additions and 2 deletions

View File

@@ -87,8 +87,8 @@ class StockLocationOrderpoint(models.Model):
_sql_constraints = [
(
"location_route_unique",
"unique(location_id, route_id)",
"The combination of Company, Location and Route must be unique",
"unique(location_id, route_id, company_id, replenish_method)",
"The combination of Company, Location, Route and Replenish method must be unique",
)
]

View File

@@ -17,6 +17,7 @@
<field name="trigger" />
<field name="replenish_method" />
<field name="group_id" />
<field name="priority" optional="hide" />
<field
name="company_id"
optional="hide"