ParamQuery grid support forum

General Category => ParamQuery Pro Evaluation Support => Topic started by: stevejacobsen on May 19, 2016, 06:32:49 am

Title: populating filter select
Post by: stevejacobsen on May 19, 2016, 06:32:49 am
I have this in my colmodel:

            {title: "Aisle", width: 50, dataIndx: "Aisle", align: "center",
                filter: {
                    type: 'select',
                    condition: 'equal',
                    listeners: ['change']
                }
            },

and this in my obj var:

            create: function (evt, ui) {
                var grid = this,
                        column;
                $.getJSON("utilities/ajax_getaisles_JSON.php", function (response) {
                    column = grid.getColumn({dataIndx: 'Aisle'});
                    column.filter.options = response;
                });

            },


it puts 76 items in the options array but they don't display.
Title: Re: populating filter select
Post by: paramvir on May 19, 2016, 08:08:59 am
Code: [Select]
column = grid.getColumn({dataIndx: 'Aisle'});
column.filter.cache = null; //clear previous cache if any.
column.filter.options = response;
grid.refreshHeader();
Title: Re: populating filter select
Post by: stevejacobsen on May 19, 2016, 08:27:06 am
Perfect! Thanks!