Server side filter list

We have a very large dataset so I implemented everything to be server side (paging, editing, sorting, inserting, searching) but I am having an issue with the filter.

When the filter icon is clicked, I can step through the code and see it is calling my controller (mvc 4) and I see the RequestType is "FilterChoiceRequest". My controller is currently just passing back a page worth of data. I don't want to pass back all my data and am wondering if I can just pass back some kind of enumeration  for ONLY the column the FilterChoiceRequest is coming in for.

The other workaround that I was trying was to remove the list that pops up and type whatever I want in the text box of the filter window. But the "ok" button gets disabled. If I enabled it using my dev tools in chrome, I can force the filter request to go back to the server and do my filtering logic. But, I can't expect my users to force that button to go back to enabled. Is it possible to latch onto a call that I can reenable the "ok" button?

Thanks.

5 Replies

SS Satheeskumar S Syncfusion Team September 4, 2013 12:42 PM UTC

Hi Donald,


Thanks for your interest in Syncfusion Products.

Query- 1 Enable OK Button If user enter the wrong entry in Filter Text Box

This is the default behavior. We are used Microsoft Excel behavior in our grid and we are unable to change this (" "OK" button is grayed out").

Query- 2 Pass Some Kind of Enumeration.

We are sorry for the inconvenience caused. We are unable to understand your requirement. Could you please give more information regarding your requirement? Such as what data you have passed to controller, what kind of enumeration you have passed to controller? So that we could able to analyze and provide you a better solution?


Please let us know if you need any further assistance.

 

Regards,

Satheeskumar S



DH Donald Hansen September 6, 2013 12:38 AM UTC

In regards to Q2 ... The grid only knows about 10 records and 13 columns. So, when the filter box pops up for column 1, it only knows about 10 items to filter on.

My question is, can I pass it a larger list separately. I don't want to pass the grid my entire dataset (100,000 rows by 13 columns). I only want to pass it an IEnumerable<string> or something like that.


MK Maithiliy K Syncfusion Team September 18, 2013 01:03 PM UTC

We will not process with custom Filtering. We have set the values on the filters array in OnActionBegin, so the null values are passed FilterDescriptor on the post action. When we passing null FilterDescriptor on the GridAction it will display all the possible values in the filteringdialog on the grid. it will also work with custom filtering. Please refer the below code snippet.

[Index.cshtml]

<script type="text/javascript">

var temp;

function Begin(sender, args) {

if (args.requestType = "FilterChoiceRequest") {

temp = sender._filters;

sender._filters = [];

}

}

function Success(sender, args) {

if (args.RequestType = "FilterChoiceRequest") {

sender._filters = temp;

}

}

</script>

For your convenience, we have prepared a simple to demonstrate this and the same can be downloaded from the below link.

Sample: Filtering.zip

Please try the above sample, and if it does not meets your requirement, could you please provide more information on this so that we can provide a better solution quickly?.

Regards,

Maithiliy K



PR prasanjit replied to Satheeskumar S January 9, 2018 01:33 PM UTC

Hi Donald,


Thanks for your interest in Syncfusion Products.

Query- 1 Enable OK Button If user enter the wrong entry in Filter Text Box

This is the default behavior. We are used Microsoft Excel behavior in our grid and we are unable to change this (" "OK" button is grayed out").

Query- 2 Pass Some Kind of Enumeration.

We are sorry for the inconvenience caused. We are unable to understand your requirement. Could you please give more information regarding your requirement? Such as what data you have passed to controller, what kind of enumeration you have passed to controller? So that we could able to analyze and provide you a better solution?


Please let us know if you need any further assistance.

 

Regards,

Satheeskumar S


I want the example in angular js and mvc. Not able to upload a doc file edit it and save it again. Could u please help me out


SE Sathyanarayanamoorthy Eswararao Syncfusion Team January 10, 2018 12:41 PM UTC

Hi Donald, 

We have checked and we are quite unclear regarding the information. So can you please provide more details about your requirement. In the previous update we have provided a sample in classic grid.  

Please provide the following details. 

  1. Do you want the sample in mvc classic?

  1. If so then please explain more about your requirement.
 
  1. Share the Syncfusion Essential Studio version details.
 
  1. You have mentioned about uploading and editing and saving a file which is about editing feature in grid?
 
 

The provided information will be help us to analyze and provide the solution as quickly as possible. 
 

Regards, 
Sathyanarayanamoorthy 


Loader.
Up arrow icon