Home Implementation advice for a query-based filter (asp.net core 2.0)
Reply: 0

Implementation advice for a query-based filter (asp.net core 2.0)

Megid Published in 2018-01-12 13:04:53Z

Note: (what I mean by query-based filter) the filter can have as many items as the user chooses. Each item contains a dropdown for the attributes of the object (like Title, CreationDate, etc), a dropdown for operators (Equals, Contains, etc), and a field which represents the thing you are comparing said attribute values with. Filters can be saved and loaded from the database as well.

The filter itself I can manage with but how to integrate it with the rest of the site is another problem. I already have a page where I list the objects, so I thought of putting the filter there, but then what do I use the model for, a list of objects or a list of filter items? How do I submit the filter data to the controller to have the objects returned? I thought of doing it through javascript only, just collect the values of all the filter items and send it through ajax to the controller but there are other parameters I have to send not just the data, which makes it hard for a beginner like me to figure out.

How could I implement this?

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.313363 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO