flectra/addons/purchase/data/purchase_stock_demo.yml
flectra-admin 769eafb483 [INIT] Inception of Flectra from Odoo
Flectra is Forked from Odoo v11 commit : (6135e82d73)
2018-01-16 11:45:59 +05:30

9 lines
320 B
YAML

-
!python {model: stock.warehouse, id: False}: |
pull_obj = self.env['procurement.rule']
wh_to_assign = ['stock_warehouse_shop0']
for wh_ref in wh_to_assign:
warehouse = self.browse(ref('stock.' + wh_ref))
#Force the rewriting of route and rule
warehouse.write({'buy_to_resupply': True})