This is a migrated thread and some comments may be shown as answers.

[Solved] onDataBinding e.data = { empID: empID } broke between 2011.1.315 and 2011.2.712

5 Answers 65 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ronald
Top achievements
Rank 1
Ronald asked on 20 Jul 2011, 05:47 PM
Hi,

The following code was working fine with version  2011.1.315

    function grid_onDataBinding(e) {
        e.data = { seaID: $("#seaID").val() };
    }

When I upgrade to version 2011.2.712 the value seaID is being append to the class GridState

Here is the firebug post value

{"state":{"page":"2","size":"10","seaID":"1"}}

Thanks

5 Answers, 1 is accepted

Sort by
0
Accepted
Atanas Korchev
Telerik team
answered on 21 Jul 2011, 08:16 AM
Hello Ronald,

 I managed to reproduce this problem locally. Find attached an updated version of telerik.grid.min.js which should address the bug.

 I also updated your Telerik points.

Regards,
Atanas Korchev
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

0
Ronald
Top achievements
Rank 1
answered on 27 Jul 2011, 08:47 PM
Thanks Atanas Korchev,

The js you prove fix this problem, but introduce a new one.
Now the data grid is not rendering the returned json into the grid, it leaves the grid empty.
I verified the json response on Firebug and it looks ok, but it's not rendering into a grid.

Please let me know.

Thanks
0
Atanas Korchev
Telerik team
answered on 28 Jul 2011, 08:57 AM
Hello Ronald,

Unfortunately I cannot reproduce this problem locally. Could you post a sample project so we can take a closer look?

Regards,
Atanas Korchev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

0
Ronald
Top achievements
Rank 1
answered on 29 Jul 2011, 04:17 AM
Hi,

I'm working to provide you a sample of my project, so that you can reproduce the error, but since it's a big project it's taking me some time.

While working to provide you the sample project I pinpoint the error.

This work without problems.

@(Html.Telerik().Grid(Model)
        .Name("Seasons") //the name cann't have blank spaces
        .DataBinding(dataBinding =>
        {
            dataBinding.WebService()
                .Select("~/Models/Season.svc/Select");
        })
        .Columns(columns =>
        {
            columns.Bound(o => o.name).Title("Name").Width(200);
        })
        )

But when I make the Grid editable it dosen't render the json result into a grid.
This does not work.

 @(Html.Telerik().Grid(Model)
        .Name("Seasons") //the name cann't have blank spaces
        .Editable(editing => editing.Mode(GridEditMode.InLine))
        .DataKeys(keys => { keys.Add(o => o.id); })
        .DataBinding(dataBinding =>
        {
            dataBinding.WebService() //to use webservices, they must be configured in the web.config
                .Select("~/Models/Season.svc/Select")
                .Update("~/Season.svc/Update");
        })
        .Columns(columns =>
        {
            columns.Bound(o => o.name).Title("Name").Width(200);
            columns.Command(commands =>
            {
                commands.Edit().ButtonType(GridButtonType.Image);
            }).Title("Actions");

        })
        )

Please let me know if with this you can reproduce the error, while I continue working to send you the sample project.
Remember I'm working with the telerik.grid.min.js you provide me.

Thanks
0
Atanas Korchev
Telerik team
answered on 29 Jul 2011, 07:42 AM
Hi Ronald,

 I am afraid I don't reproduce this problem based on the provided code. Perhaps the grid javascript file is not sufficient for the update. Please find attached a complete hotfix build. The full update of all javascript files may fix the problem. If it doesn't you can send us a sample project.

Regards,
Atanas Korchev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Tags
Grid
Asked by
Ronald
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Ronald
Top achievements
Rank 1
Share this question
or