Skip to content

Commit

Permalink
minor name fix
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinkhao committed Oct 25, 2023
1 parent 6e6052f commit ede086a
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions wms_connector/models/stock_warehouse.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@

FILTER_VALS = {
"wms_export_product_filter_id": {
"name": "WMS: Default filter for product sync",
"name": "WMS: {} filter for product sync",
"model_id": "wms.product.sync",
},
"wms_export_picking_in_filter_id": {
"name": "WMS: Default filter for picking in",
"name": "WMS: {} filter for picking in",
"model_id": "stock.picking",
},
"wms_export_picking_out_filter_id": {
"name": "WMS: Default filter for picking out",
"name": "WMS: {} filter for picking out",
"model_id": "stock.picking",
},
}
Expand Down Expand Up @@ -155,6 +155,8 @@ def _activate_filters(self):
if ir_filter:
ir_filter.active = True
else:
vals = vals.copy()
vals["name"] = vals["name"].format(self.name)
self[filter_fieldname] = self.env["ir.filters"].create(vals)
self.wms_export_product_filter_id.domain = FILTER_DOMAINS[
"wms_export_product_filter_id"
Expand Down

0 comments on commit ede086a

Please sign in to comment.