changeset 6edaaba16b00 in modules/stock_supply_production:default
details:
https://hg.tryton.org/modules/stock_supply_production?cmd=changeset&node=6edaaba16b00
description:
Add warehouses selection to supply stock wizard
issue10532
review353701002
diffstat:
stock.py | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diffs (16 lines):
diff -r 83ebd3387905 -r 6edaaba16b00 stock.py
--- a/stock.py Wed Apr 06 23:37:44 2022 +0200
+++ b/stock.py Thu Apr 07 00:06:34 2022 +0200
@@ -94,7 +94,11 @@
@property
def _production_parameters(self):
- return {}
+ parameters = {}
+ # Use getattr because start is empty when run by cron
+ if getattr(self.start, 'warehouses', None):
+ parameters['warehouses'] = self.start.warehouses
+ return parameters
def generate_production(self, clean):
pool = Pool()