Default Filter unless searching

Discussions related to customizing hooks. Hooks are documented at http://bigprof.com/appgini/help/advanced-topics/hooks/
Post Reply
HBmike
Posts: 18
Joined: 2013-08-30 18:02

Default Filter unless searching

Post by HBmike » 2014-02-11 18:32

Hello,

I am trying to set up a hook to implement a filter to not show the closed orders unless someone is doing a search. I have tried various variations but it is not working. Basically checking to see if there is a search string then it will not add the filter. Here is what I have so far;

Code: Select all


                function orders_init(&$options, $memberInfo, &$args){

/* My code starts here */
if (empty($_POST['SearchString'])) {
addFilter(1, 'or', 5, '!=', 'Closed');
} 
/* My code ends */
		return TRUE;
	}



Thanks for any ideas!

HBmike
Posts: 18
Joined: 2013-08-30 18:02

Re: Default Filter unless searching

Post by HBmike » 2014-02-18 15:43

Still trying to figure this out. Any ideas?

Thanks!

Post Reply