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

[Solved] Customizing Edit button in new release?

2 Answers 63 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.
H
Top achievements
Rank 1
H asked on 21 Mar 2011, 06:04 PM
Hi,

We are using the following in jQuery (Ajax binding) to customize Edit buttons in a grid:

$(

 

'#ProductsGrid').tGrid.defaults.localization['edit'] = 'Add to Cart'

;

 

 

 

 

 


With the new release (2011.1.315), this stopped working & the Edit buttons just say Edit.

Any suggestions?

Thank you.

2 Answers, 1 is accepted

Sort by
0
Accepted
Atanas Korchev
Telerik team
answered on 22 Mar 2011, 09:05 AM
Hi H,

This is a regression caused by one optimization change of the grid. You can use this code as a workaround (you have to subscribe to the onload event of the grid):

<script type="text/javascript">

function onLoad() {
    var grid = $(this).data("tGrid");
    grid.localization["edit"] = "Add to cart";
    grid.initializeColumns();
}

</script>

All the best,
Atanas Korchev
the Telerik team
0
H
Top achievements
Rank 1
answered on 22 Mar 2011, 01:52 PM
That fixed it.

Thank you!
Tags
Grid
Asked by
H
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
H
Top achievements
Rank 1
Share this question
or