public static HtmlString GetHtmlRowsModel(this IHtmlHelper <IEnumerable <Pais> > helper, IEnumerable <Pais> model) { string html = string.Empty; foreach (Pais item in model.ToList()) { html += string.Concat("<tr> ", helper.SDisplayFor(modelItem => item.Id), helper.SDisplayFor(modelItem => item.Nome), helper.ActionButtons(route: item.Id).ToHtmlString(), "</tr> "); } return(new HtmlString(html)); }