jQWidgets Forums

jQuery UI Widgets Forums Grid Problem with filter with checkedList

This topic contains 1 reply, has 2 voices, and was last updated by  Dimitar 9 years, 2 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Problem with filter with checkedList #81634

    Adjo
    Participant

    Hi!

    I am testing with a jqxgrid. But I have a problem with the filterrow on a column with filtertype ‘checkedList’.
    The code is:

    
        <script type="text/javascript" src="jqwidgets/jqxcore.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxdata.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxbuttons.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxscrollbar.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxmenu.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.selection.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.edit.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxcheckbox.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxlistbox.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.filter.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.edit.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxdropdownlist.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxcombobox.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxgrid.sort.js"></script>
        <script type="text/javascript" src="jqwidgets/jqxpanel.js"></script> 
        <script type="text/javascript">
            $(document).ready(function () {
                LoadData();
            });
    
            function LoadData() {
                var Srcleveranciers = {
                    datatype: 'json',
                    datafields: [
                    { name: 'TeelerID' },
                    { name: 'Teeler' }
                    ],
                    url: 'data/getLeveranciers.php',
                    async: false
                };
                var daLeveranciers = new $.jqx.dataAdapter(Srcleveranciers, {
                    autoBind: true
                });
    
                var data = {};
                var theme = 'classic';
                var source =
                  {
                      datatype: "json",
                      cache: false,
                      datafields: [
                           { name: 'ID' },
                           { name: 'TeelerID', type: 'text' },
                           { name: 'Teeler', value: 'TeelerID', values: { source: daLeveranciers.records, value: 'TeelerID', name: 'Teeler' } },
                      ],
                      id: 'ID',
                      url: 'data/Artikelregels.php'
                  };
    
                var dataAdapter = new $.jqx.dataAdapter(source);
                $("#jqxgrid").jqxGrid(
               {
                   editable: true,
                   selectionmode: 'singlecell',
                   filterable: true,
                   showfilterrow: true,
                   sortable: true,
                   width: '100%',
                   height: 350,
                   source: dataAdapter,
                   theme: theme,
                   columns: [
                         { text: 'ID', datafield: 'ID', width: 100 },
                         {
                             text: 'Teeler', datafield: 'TeelerID', displayField: 'Teeler', columntype: 'dropdownlist', filtertype: 'checkedlist', width: 200,
                             createeditor: function (row, value, editor) {
                                 editor.jqxDropDownList({ source: daLeveranciers, displayMember: 'Teeler', valueMember: 'TeelerID' });
                             }
                         }
                   ]
               });
            }
        </script>
    </head>
    <body>
        <div class="container">
            <div id="jqxgrid">
            </div>
    
        </div>
    
    </body>
    </html>

    The checklist and dropdownlist (for editing) looks fine. But when I try to filter on that column I get the following javascript error:

    TypeError: b is null
    …=undefined||f==null){return}f.filter=e;b.filter=e;this.dataview.addfilter(d,e);i…
    jqxgrid.filter.js
    Line 7

    Filtering on a other textcolumn is working fine. Does anyone have an idea?

    Thanks!

    Problem with filter with checkedList #81656

    Dimitar
    Participant

    Hi Adjo,

    Please make sure you are using the latest version of jQWidgets (4.0.0). If the issue persists, please share some sample data so that we can test your example locally and determine why the issue occurs.

    Best Regards,
    Dimitar

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

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

You must be logged in to reply to this topic.