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

Accessing the Ajax Complete event when using the MVC Listview wrapper

0 Answers 102 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Martin Kelly
Top achievements
Rank 1
Martin Kelly asked on 23 Jul 2012, 07:46 AM
I am using MVC4 with the latest Kendo UI Q2. I am trying to use the mvc wrappers to implement a list view with a view template and an edit template.

How can I access the Ajax complete event when using the MVC wrappers?

@(Html.Kendo().ListView<iProjX.Models.RoleModel>(Model.Roles)
    .Name("rolesListView")       
    .TagName("div")       
    .ClientTemplateId("rolesList")       
    .Editable()
    .Pageable()
    .DataSource(dataSource => dataSource           
        .Model(model =>
            {
                model.Id("RoleId");
                model.Field(f => f.ProjectId).DefaultValue(Model.ProjectId);
                model.Field(f => f.Title);
                model.Field(f => f.Description);;
            })
        .Events(e => e               
            .Error("rolesListViewData_error")
            .Change("rolesListViewData_change")
            .RequestStart("rolesListViewData_requestStart"))          
        .Create(create => create.Action("createRole", "Project"))           
        .Read(read => read.Action("getRoles", "Project", new { projectId = Model.ProjectId }))
        .Update(update => update.Action("updateRole", "Project"))   
        .PageSize(30)           
     )
    .Events(e => e
        .Change("rolesListView_change")
        .Edit("rolesListView_edit")
        .DataBound("rolesListView_databound"))     
)

No answers yet. Maybe you can help?

Tags
ListView
Asked by
Martin Kelly
Top achievements
Rank 1
Share this question
or