changeset 1f608370cd32 in modules/stock:default
details: https://hg.tryton.org/modules/stock?cmd=changeset&node=1f608370cd32
description:
        Limit assign to contextual company

        issue11010
        review376111002
diffstat:

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

diffs (13 lines):

diff -r 0f21c72fc9ef -r 1f608370cd32 shipment.py
--- a/shipment.py       Sat Dec 18 16:34:36 2021 +0100
+++ b/shipment.py       Tue Dec 21 23:14:59 2021 +0100
@@ -76,7 +76,9 @@
     def _get_assign_domain(cls):
         pool = Pool()
         Date = pool.get('ir.date')
+        context = Transaction().context
         return [
+            ('company', '=', context.get('company')),
             ('state', '=', 'waiting'),
             ('planned_date', '=', Date.today()),
             ]

Reply via email to