kendo ui datasource mapping of the model fails

2 posts, 0 answers
  1. dávid
    dávid avatar
    1 posts
    Member since:
    May 2016

    Posted 13 May 2016 Link to this post

    we would like to migrate our grid to Kendo UI grid and if it fits for us we will buy it. I tried to implement it, but I'm blocked with an issue. The id column works only if I provide 'id' instead of '_id' in the json and all the json property have to be the same as the model and column fild name.

    For example if You change the 'title' filed to 'title2' and do the same in the column settings, the grid fails, there are empty columns. Or if I change the '_id' to 'id' the id column will contanins the values.

    So for me it seems the mapping of the model fails, the 'from' doesn't work properly.

    Check the example in jsbin: http://jsbin.com/welone/1/edit?html,css,js,output

  2. Rosen
    Admin
    Rosen avatar
    3253 posts

    Posted 17 May 2016 Link to this post

    Hello David,

    The cause for the behavior you have observed is misplacement of schema configuration. In the sample you have provided, the schema definition is placed as part of the transport settings. However, it should be directly placed bellow the dataSource configuration. Here is an updated version of the test page you have provided.

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