I'm trying to create a script that looks for open orders that are pending fulfillment, even though the customer is overdue. The script will change the status of the order to Pending Approval. Everything works properly unless it hits an order that contains a line with a drop ship item. It cannot set it to pending approval. I'm OK with ignorning these orders, but I cannot figure out how to exclude these type of orders from the search.
Reviewing the records browser, I see "createdpo" and "createpo" which are under the "item" sublist as a "select" field. Whichever way I try to reference this fails. I've tried to build this saved search in the UI and also cannot find out how to do this.
Does anyone have any ideas?
Currently I'm using:
filters[0] = new nlobjSearchFilter("mainline",null,"is","T"); filters[1] = new nlobjSearchFilter("status",null,"is","SalesOrd:B"); filters[2] = new nlobjSearchFilter("daysoverdue","customer","greaterthan","31");I've tried the following variations with no success:filters[3] = new nlobjSearchFilter("createpo","item","is",null); filters[3] = new nlobjSearchFilter("createdpo","item","is",null); filters[3] = new nlobjSearchFilter("createpo",null,"is",null); filters[3] = new nlobjSearchFilter("createdpo",null,"is",null);Each of those gives me an error error: An nlobjSearchFilter contains invalid search criteria: createpo (or createdpo)