26 lines
1.5 KiB
Plaintext
26 lines
1.5 KiB
Plaintext
@model PollModel
|
|
|
|
@{
|
|
const string hideInfoBlockAttributeName = "PollPage.HideInfoBlock";
|
|
var customer = await workContext.GetCurrentCustomerAsync();
|
|
var hideInfoBlock = await genericAttributeService.GetAttributeAsync<bool>(customer, hideInfoBlockAttributeName);
|
|
|
|
const string hideAnswersBlockAttributeName = "PollPage.HideAnswersBlock";
|
|
var hideAnswersBlock = await genericAttributeService.GetAttributeAsync<bool>(customer, hideAnswersBlockAttributeName, defaultValue: true);
|
|
}
|
|
|
|
<div asp-validation-summary="All"></div>
|
|
<input asp-for="Id" type="hidden" />
|
|
|
|
<section class="content">
|
|
<div class="container-fluid">
|
|
<div class="form-horizontal">
|
|
<nop-cards id="poll-cards">
|
|
<nop-card asp-name="poll-info" asp-icon="fas fa-info" asp-title="@T("Admin.ContentManagement.Polls.Info")" asp-hide-block-attribute-name="@hideInfoBlockAttributeName" asp-hide="@hideInfoBlock" asp-advanced="false">@await Html.PartialAsync("_CreateOrUpdate.Info", Model)</nop-card>
|
|
<nop-card asp-name="poll-answers" asp-icon="fas fa-commenting" asp-title="@T("Admin.ContentManagement.Polls.Answers")" asp-hide-block-attribute-name="@hideAnswersBlockAttributeName" asp-hide="@hideAnswersBlock" asp-advanced="false">@await Html.PartialAsync("_CreateOrUpdate.Answers", Model)</nop-card>
|
|
|
|
@await Component.InvokeAsync(typeof(AdminWidgetViewComponent), new { widgetZone = AdminWidgetZones.PollDetailsBlock, additionalData = Model })
|
|
</nop-cards>
|
|
</div>
|
|
</div>
|
|
</section> |