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

[Solved] Grid commands problem

0 Answers 30 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
lichuan
Top achievements
Rank 1
lichuan asked on 17 Jan 2011, 03:01 PM
I'm tring to show a grid like this. Once I add either TooBar or columns.command, All the links and buttons will not work (not clickable).
Please help!

Html.Telerik().Grid(Model)
        .Name("Grid")
        .DataKeys(key => key.Add(e => e.EmployeeId))
        .DataBinding(dataBinding =>
        {
            dataBinding.Ajax()
                      .Select("_SelectAjaxEdit", "Employee")
                      .Update("_UpdateAjaxEdit", "Employee")
                      .Delete("_DeleteAjaxEdit", "Employee")
                      .Insert("_InsertAjaxEdit", "Employee");
        })
        .ToolBar(commands => commands.Insert())                             
        .Columns(columns =>
        {
            columns.Bound(e => e.GIN).ClientTemplate("<img src='/Employee/Avatar?id=<#= EmployeeId #>' width='35' height='35' alt='<#= LDAP #>'/>")
                .Width(40);
            columns.Bound(e => e.LDAP).Width(60);
            columns.Bound(e => e.Status).Width(50);
            columns.Bound(e => e.Mobile);
            columns.Command(commands =>
            {
                commands.Edit();
                commands.Delete();
            }).Width(180).Title("Commands");
        })
        .Editable(editing => editing.Mode(GridEditMode.PopUp))
        .Pageable(paging => paging.PageSize(5))
        .Render();
Tags
General Discussions
Asked by
lichuan
Top achievements
Rank 1
Share this question
or