changeset 6620112cccc4 in modules/stock:default
details: https://hg.tryton.org/modules/stock?cmd=changeset;node=6620112cccc4
description:
        Keep the original context when opening Product Quantities by Warehouse

        The PYSON context only works when it is evaluated from keyword action.
        When it is evaluated as the result of a wizard, there is no more any 
active*
        keys in the context. So we must not change the context as we already 
have the
        right inherited one from the view.

        issue9884
        review324561002
diffstat:

 product.py |  1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diffs (11 lines):

diff -r b7473de967d6 -r 6620112cccc4 product.py
--- a/product.py        Mon Nov 23 23:36:02 2020 +0100
+++ b/product.py        Fri Dec 04 18:39:12 2020 +0100
@@ -601,6 +601,7 @@
 
     def do_open_(self, action):
         domain = [('date', '>=', self.record.date)]
+        action['pyson_context'] = '{}'
         action['pyson_search_value'] = PYSONEncoder().encode(domain)
         action['name'] += ' (' + self.record.rec_name + ')'
         return action, {}

Reply via email to