简体   繁体   中英

Add footer row to grid.mvc

I want to add a footer row were the user can add a new item like on this image. 页脚的图像 I am using gid.MVC by Vyacheslav Bukharin. As you can see in this tutorial https://www.c-sharpcorner.com/UploadFile/4d9083/creating-simple-grid-in-mvc-using-grid-mvc/

here is my code so far

@Html.Grid(Model).Columns(columns =>
                {
                    columns.Add(c => c.cliente_id).Titled("Cliente ID");
                    columns.Add(c => c.nombre_cliente).Titled("Cliente name");
                    columns.Add()
                    .Filterable(false)
                    .Encoded(false)
                    .Sanitized(false)
                    .SetWidth(30)
                    .RenderValueAs(o => Html.ActionLink("Edit", "Edit", new { id = o.cliente_id }));
                    columns.Add()
                    .Encoded(false)
                    .Sanitized(false)
                    .SetWidth(30)
                    .RenderValueAs(o => Html.ActionLink("Delete", "Delete", new { id = o.cliente_id }));                        
                    }).WithPaging(10).Sortable(true).Filterable(true).WithMultipleFilters()

My question is how can i add the same footer as on the image in mvc. Thank you for your help

Include gridmvc.css to your layout.cshtml .filteriing and paging will start working.

<link href="@Url.Content("~/Content/Gridmvc.css")" rel="stylesheet" 
type="text/css" />

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM