Duplicate
Details
Assignee
Pritesh ShahPritesh ShahReporter
R MathebulaR MathebulaPriority
Major
Details
Details
Assignee
Pritesh Shah
Pritesh ShahReporter
R Mathebula
R MathebulaPriority
Created April 11, 2018 at 4:18 PM
Updated June 2, 2018 at 12:52 PM
Resolved April 12, 2018 at 11:18 AM
Create new client say TestClient
Login to GardenWorld client
Open Workflow window
search for Process_Order
Navigate to Node tab and open (DocPrepare)
Navigate to Transition tab
add new condition in Condition tab for transition (DocPrepare) -> (DocComplete)
Grand Total < 5000
Save it
Login to Test Client
Create Sales Order of grand total 5100
On complete, workflow will hang because condition applied in GardenWorld client got applied to TestClient as well.
Solution:
Add client id in where condition when getting conditions of transition node as below
final String whereClause = MWFNextCondition.COLUMNNAME_AD_WF_NodeNext_ID+"=? AND AD_Client_ID(0,?)";
List<MWFNextCondition> list = new Query(getCtx(), MWFNextCondition.Table_Name, whereClause, get_TrxName())
.setParameters(new Object[]{getAD_WF_NodeNext_ID(), Env.getAD_Client_ID(Env.getCtx())})
.setOnlyActiveRecords(true)
.setOrderBy(MWFNextCondition.COLUMNNAME_SeqNo)
.list();