Webiant Logo Webiant Logo
  1. No results found.

    Try your search with a different keyword or use * as a wildcard.

List.cshtml

@model PollSearchModel

@{
    //page title
    ViewBag.PageTitle = T("Admin.ContentManagement.Polls").Text;
    //active menu item (system name)
    NopHtml.SetActiveMenuItemSystemName("Polls");
}

@{
    const string hideSearchBlockAttributeName = "PollsPage.HideSearchBlock";
    var hideSearchBlock = await genericAttributeService.GetAttributeAsync(await workContext.GetCurrentCustomerAsync(), hideSearchBlockAttributeName);
}


@T("Admin.ContentManagement.Polls")

@T("Admin.Common.AddNew") @await Component.InvokeAsync(typeof(AdminWidgetViewComponent), new { widgetZone = AdminWidgetZones.PollListButtons, additionalData = Model })
@*hide the entire search block if no elements are displayed*@
@await Html.PartialAsync("Table", new DataTablesModel { Name = "polls-grid", UrlRead = new DataUrl("List", "Poll", null), SearchButtonId = "search-poll", Length = Model.PageSize, LengthMenu = Model.AvailablePageSizes, Filters = new List { new FilterParameter(nameof(Model.SearchStoreId)) }, ColumnCollection = new List { new ColumnProperty(nameof(PollModel.Name)) { Title = T("Admin.ContentManagement.Polls.Fields.Name").Text }, new ColumnProperty(nameof(PollModel.LanguageName)) { Title = T("Admin.ContentManagement.Polls.Fields.Language").Text, Width = "100" }, new ColumnProperty(nameof(PollModel.DisplayOrder)) { Title = T("Admin.ContentManagement.Polls.Fields.DisplayOrder").Text, Width = "100", ClassName = NopColumnClassDefaults.CenterAll }, new ColumnProperty(nameof(PollModel.Published)) { Title = T("Admin.ContentManagement.Polls.Fields.Published").Text, Width = "100", ClassName = NopColumnClassDefaults.CenterAll, Render = new RenderBoolean() }, new ColumnProperty(nameof(PollModel.ShowOnHomepage)) { Title = T("Admin.ContentManagement.Polls.Fields.ShowOnHomepage").Text, Width = "100", ClassName = NopColumnClassDefaults.CenterAll, Render = new RenderBoolean() }, new ColumnProperty(nameof(PollModel.StartDateUtc)) { Title = T("Admin.ContentManagement.Polls.Fields.StartDate").Text, Width = "150", Render = new RenderDate() }, new ColumnProperty(nameof(PollModel.EndDateUtc)) { Title = T("Admin.ContentManagement.Polls.Fields.EndDate").Text, Width = "150", Render = new RenderDate() }, new ColumnProperty(nameof(PollModel.Id)) { Title = T("Admin.Common.Edit").Text, Width = "100", ClassName = NopColumnClassDefaults.Button, Render = new RenderButtonEdit(new DataUrl("Edit")) } } })