This is a migrated thread and some comments may be shown as answers.

how can i get the second textbox in custom filter?

0 Answers 21 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Eugene
Top achievements
Rank 1
Eugene asked on 19 Mar 2012, 10:23 AM
Hi, may i know how can i get the second textbox in the custom filter template?
below is the code i used, but couldnt find a way to replace the second textbox..


 function onLoad() {
               $("#grid th:contains(Status)")
            .find(".t-grid-filter")
            .click(function (e) {
                var filterIcon = $(this);

                var select = $("<select><option value=''>-- select --</option><option>Approved</option><option>Closed</option></select>");

                setTimeout(function () {
                    var filterMenu = filterIcon.data("filter");
                    filterMenu.find(":text").first().replaceWith(select);  // replace the first textbox with the new filter UI
                });
            });
           }
Tags
Grid
Asked by
Eugene
Top achievements
Rank 1
Share this question
or