Lookup not working on Tab level, wrong context parsing, MLookup not fully implemented

Description

I'm trying the following:
In the Material Receipt window, i added another WSearchEditor field for M_Product_ID Lookup. I want to use this field to only show the orders of the current selected Business Partner which contain (a) certain product/s (when using multi select in the Lookup popup).

The problem is when i create the MLookup for the WSearchEditor, i provide it the WindowNo (which is the same as the Material Receipt window) and the TabNo (which is 1113, hard coded in Env.TAB_INFO).

The MLookup constructor takes the TabNo but i found out that it is never used in the code. The next thing is that in the WSearchEditor.getWhereClause() Env.parseContext(Env.getCtx(), lookup.getWindowNo(), whereClause, false); is called. This method ignores the TabNo.

My suggestion is to store the TabNo in the MLookup and create a getter method for it. Then i would add another parseContext() method which takes the tabno

Environment

None

Assignee

Unassigned

Reporter

Jan Thielemann

Labels

None

Tested By

None

Priority

Major
Configure