This question is locked. New answers and comments are not allowed.
Hey Telerik!
I just fixed a problem where the client side javascript onSave was not working. The reason was because I was binding the 'DateCreated' column with the grid and I had that specific property set to [ScaffoldColumn(false)] in MVC.
My new question is: How can I add a callback function on a commands.Edit() Essentially, I would like to
1. Click Edit or Delete
2. Have the MVC code update the record in the database and return that everything was good, etc.
3. Callback code is ran and a request is made to refresh the list.
We are using RavenDB and are experiencing ui problems with list items being deleted and then a new query being ran for the new list of items to be show and returned (in the same controller method)
Thanks as always
Ryan
I just fixed a problem where the client side javascript onSave was not working. The reason was because I was binding the 'DateCreated' column with the grid and I had that specific property set to [ScaffoldColumn(false)] in MVC.
My new question is: How can I add a callback function on a commands.Edit() Essentially, I would like to
1. Click Edit or Delete
2. Have the MVC code update the record in the database and return that everything was good, etc.
3. Callback code is ran and a request is made to refresh the list.
We are using RavenDB and are experiencing ui problems with list items being deleted and then a new query being ran for the new list of items to be show and returned (in the same controller method)
Thanks as always
Ryan
@(Html.Telerik().Grid(Model) .Name("Grid") .DataKeys(keys => keys.Add(o => o.Id)) .Columns(columns => { columns.Bound(o => o.PartNumber).Width(100); columns.Command(commands => { commands.Edit().ButtonType(GridButtonType.ImageAndText); commands.Delete().ButtonType(GridButtonType.ImageAndText); }).Width(200).Title("Commands"); }) .DataBinding(dataBinding => dataBinding.Ajax() .Select("_Index", "Gage") .Update("_Save", "Gage") .Delete("_Delete", "Gage")) .ClientEvents(events => events .OnSave("onSave")) .Groupable() .Sortable() .Pageable() .Editable(x => x.Mode(GridEditMode.PopUp)) .Filterable() ) <script type="text/javascript"> function onSave(e) { }</script>