jQuery UI Widgets Forums Grid Custom filtering

This topic contains 3 replies, has 2 voices, and was last updated by  Dimitar 10 years, 1 month ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • Custom filtering #58607

    Katashov Dima
    Participant

    Hi!
    I want to use your custom filtering. I use this code:

    $('#jqxgrid').on('filter', function (event){
    				var filterinfo = $('#jqxgrid').jqxGrid('getfilterinformation');
    					for (i = 0; i < filterinfo.length; i++) {
    						if(filterinfo[i].filtercolumn == 'bu') {//колонкa
    							var filter = filterinfo[i].filter.getfilters();
    							var value = filterinfo[i].filter.getfilters()[i].value;
    						}
    					}
    					
    });
    
    $('#jqxgrid').jqxGrid(column[{ text: 'bu', datafield: 'bu', editable: true, cellsalign: 'center', align: 'center', cellsrenderer: cellsrenderer, pinned: true, filtertype: 'list', filteritems: ['1','0'] ])
    

    How i can set names filteritems ? I want see list with [‘+’,’-‘], but values [‘1′,’0’]. How i can do this ?
    Thank you.

    Custom filtering #58619

    Dimitar
    Participant

    Hello Katashov Dima,

    Do you mean that you want the list to appear as [“+”, “-“] but have actual values of [“1”, “0”]? Unfortunately, this cannot be achieved. What you can do is have cell values “1” and “0” which appear as “+” and “-“ (or vice versa) through cellsrenderer.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

    Custom filtering #58620

    Katashov Dima
    Participant

    Yes, i use cellsrenderer to take + and – in cells, but in mysql db they are 1 and 0. And filtering work after entering 1 or 0. I want to use custom filter list, which have [1,0] values but look like [+,-].

    Custom filtering #58711

    Dimitar
    Participant

    Hi Katashov Dima,

    Unfortunately, such functionality is not available.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.