Open-source eCommerce platform for C# and ASP.NET Core 10 with MongoDB. Build multi-store shops and multi-vendor marketplaces with B2B/B2C, REST API, plugins, Vue 3 and Docker.
C# aspnet-corecsharpdockerdotnetecommerceecommerce-platformmongodbmulti-storemulti-vendornosqlonline-shopshoppingcart
@using Grand.Web.AdminShared.Models.Messages
@model ContactAttributeModel
@{
//page title
var isReadOnly = Model.IsReadOnly;
ViewBag.Title = Loc["Admin.Catalog.Attributes.ContactAttributes.EditAttributeDetails"];
var area = ViewContext.RouteData.Values["area"]?.ToString();
}
<form asp-area="@area" asp-controller="ContactAttribute" asp-action="Edit" method="post" id="contactattribute-form">
@* the checkout attribute edit screen's shell: the attribute's name as the title, Save as the
one primary action and Delete in the overflow menu; a global attribute a store owner may
only look at gets neither, and says so where the actions would be *@
<admin-page sticky
title="@Model.Name"
icon="bi-card-list"
meta="@Loc["Admin.Catalog.Attributes.ContactAttributes.EditAttributeDetails"]"
back-url="@Url.Action("List")"
back-text="@Loc["Admin.Catalog.Attributes.ContactAttributes.BackToList"]">
<page-actions>
@if (!isReadOnly)
{
<button class="btn btn-outline-secondary" type="submit" name="save-continue">
<i class="bi bi-check-circle"></i> @Loc["Admin.Common.SaveContinue"]
</button>
<button class="btn btn-primary" type="submit" name="save">
<i class="bi bi-check-lg"></i> @Loc["Admin.Common.Save"]
</button>
<admin-action-menu>
<admin-action id="contactattribute-delete" destructive="true" icon="bi-trash"
text="@Loc["Admin.Common.Delete"]"/>
</admin-action-menu>
<partial name="Partials/WidgetZone.DetailsButtons" model="Model"/>
}
else
{
<span class="grand-chip grand-chip--amber">
<i class="bi bi-info-circle"></i> @Loc["Admin.Catalog.Attributes.ContactAttributes.GlobalReadOnly"]
</span>
}
</page-actions>
<partial name="Partials/CreateOrUpdate" model="Model"/>
</admin-page>
</form>
@if (!isReadOnly)
{
<admin-delete-confirmation button-id="contactattribute-delete"/>
}