----- Ursprüngliche Mail ----- > Thank you. Why is this not working?: > > stockdate = datetime.date(2012,1,1) > config._context['stock_date_end'] = stockdate > stock_2012_01_01 = product.quantity > > It always shows the stock of today, but I need stock from 2012/01/01.
It should be something like that (untested):
stockdate = datetime.date(2012, 1, 1)
with Transaction().set_context(stock_date_end=stockdate):
stock_2012_01_01 = product.quantity
--
--
[email protected] mailing list
