Fileter and Paging

6 posts, 0 answers
  1. Rajendra
    Rajendra avatar
    9 posts
    Member since:
    Feb 2015

    Posted 26 Feb 2016 Link to this post

    I  have grid with paging and filtering. Filtering use to work correctly. But as soon as I added paging , Filter does not work..  I will get processing circle if click on filter on the grid. Please see the image attached
  2. Patrick
    Admin
    Patrick avatar
    251 posts

    Posted 29 Feb 2016 Link to this post

    Hi Rajendra,

    Please take a look at this Telerik Dojo which illustrates a Kendo Grid with a Pager and Filter.  Unfortunately, I am unable to replicate your scenario.  Please update the attached dojo or create a new one with the behavior of your grid.

    For more information about filtering, take a look at this documentation and our helpful demos.

    Regards,
    Patrick
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Rajendra
    Rajendra avatar
    9 posts
    Member since:
    Feb 2015

    Posted 29 Feb 2016 in reply to Patrick Link to this post

    Please See the code below. If I remove the paging filter Works fine.

     

    $(document).ready(function () {
    var createGrid = function () {
    $("#srchgrd").kendoGrid({
    // dataSource: remoteDataSource,
    editable: false,
    selectable: true,
    //schema: {
    // data: "d.data",
    // total: "d.total"
    //},
    dataSource: new kendo.data.DataSource({
    // serverPaging: true,
    sortable: true,
    // pageSize: 3,
    buttonCount: 5,
    filterable: {
    multi: true
    },
    schema: {
    data: "d.data",
    total: "d.total",
    },
    transport: {
    read: {
    url: "/WebForm3.aspx/Getserachres2", //specify the URL which data should return the records. This is the Read method of the Products.asmx service.
    contentType: 'application/json', // tells the web service to serialize JSON
    type: "POST", //use HTTP POST request as the default GET is not allowed for ASMX
    dataType: "json"
    },

    parameterMap: function (options) {
    return kendo.stringify(options);
    },

    },
    }),
    // pageable: true,
    change: function () {
    var row = this.select();
    var id = row.data("id");
    var gview = $("#srchgrd").data("kendoGrid");
    alert("clicked");
    //Getting selected item
    var selectedItem = gview.dataItem(gview.select());
    // alert(selectedItem.DOCK_ACTIVITY_ID);
    },
    //dataSource: dataSource,
    DOCK_ACTIVITY_ID: { type: "number", editable: false },
    LOC_ABBR: { type: "string", editable: false },
    // BatchId :{ editable: true, nullable: true },
    SHIPPER_ACCT_NBR: { type: "number", editable: false },
    ORDER_ID: { type: "number", editable: false },
    VESSEL_VIN: { type: "string", editable: false },
    ShipperName: { type: "string", editable: false },
    VesselName: { type: "string", editable: false },
    CUSTOMER_PT: { type: "string" },
    columns: [
    {
    field: "DOCK_ACTIVITY_ID",
    title: "ID",
    width: "10px",
    filterable: { multi: true, search: true }
    },
    {
    field: "LOC_ABBR",
    title: "Location",
    width: "20px",
    filterable: { multi: true, search: true }
    },
    {
    field: "SHIPPER_ACCT_ABBR",
    title: "Shipper",
    width: "20px",
    filterable: { multi: true }
    },
    {
    field: "VESSEL_NAME",
    title: "Vessel",
    width: "20px",
    filterable: { multi: true }
    },
    {
    field: "CUSTOMER_PT",
    title: "DOCK",
    width: "20px",
    filterable: { multi: true }
    }


    ]
    });
    }
    createGrid();
    $("#btn").click(function () {
    var grid = $('#srchgrd').data("kendoGrid");
    grid.dataSource.read();
    grid.refresh();

    });

    });

  4. Patrick
    Admin
    Patrick avatar
    251 posts

    Posted 01 Mar 2016 Link to this post

    Hello Rajendra,

    Please take a look at this Kendo Grid using a web service, paging, and filtering.  

    I made sure to include serverPaging and serverFiltering in order to get all of my results. 

    Hopefully, this helps clear things.

    Regards,
    Patrick
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  5. Rajendra
    Rajendra avatar
    9 posts
    Member since:
    Feb 2015

    Posted 01 Mar 2016 in reply to Patrick Link to this post

    I think I got this part correct. On the Server Side I am using kendo dynamic linq.  filter object is not recognized
  6. Patrick
    Admin
    Patrick avatar
    251 posts

    Posted 03 Mar 2016 Link to this post

    Hi Rajendra,

    In order to move forward, please create a small, runnable sample which will help us focus on the specific behavior of your project.

    I look forward to your sample.

    Regards,
    Patrick
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
Back to Top