Developer forum

Forum » CMS - Standard features » ItemPublisher override filtering

ItemPublisher override filtering

Mario Santos Dynamicweb Employee
Mario Santos
Reply

Hi there,

The items we are listing (using ItemPublisher module) have a Year field and we want to pre-select the items from current year. To achieve that we add a rule for Year field with value @Code(DateTime.Now.Year). https://www.screencast.com/t/EfIeZsEHg

We need to allow end users to filter the list by Year on frontend, so we are submiting Year=2018. The module joins both Year rules - querystring and filtering - which returns no results: https://www.screencast.com/t/CvuazaN84Vfh
I tried to set the rule to @Code(System.Web.HttpContext.Current.Request["Year"] ?? DateTime.Now.Year)  but it didn't worked.

Is there a way to make the module override the module filtering?

Thanks,
BR, Mario

 


Replies

 
Nicolai Pedersen
Reply

That is not possible. Maybe you can submit to another page.

BR Nicolai

 
Mario Santos Dynamicweb Employee
Mario Santos
Reply

The downside is that they will have a few pages (different item types) like this one but we will see what we can do. Thanks!

BR, Mario

 

You must be logged in to post in the forum