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
Migrate ProductAttributeValueCreatePopup.cshtml to AdminShared (ARCH-001 Phase 2)
KrzysztofPajak0d0c5be0fd0c
diff --git a/src/Web/Grand.Web.Admin/Areas/Admin/Views/Product/ProductAttributeValueCreatePopup.cshtml b/src/Web/Grand.Web.AdminShared/Views/Product/ProductAttributeValueCreatePopup.cshtmlsimilarity index 82%rename from src/Web/Grand.Web.Admin/Areas/Admin/Views/Product/ProductAttributeValueCreatePopup.cshtmlrename to src/Web/Grand.Web.AdminShared/Views/Product/ProductAttributeValueCreatePopup.cshtmlindex 24a392b4f..a96a02328 100644--- a/src/Web/Grand.Web.Admin/Areas/Admin/Views/Product/ProductAttributeValueCreatePopup.cshtml+++ b/src/Web/Grand.Web.AdminShared/Views/Product/ProductAttributeValueCreatePopup.cshtml@@ -1,10 +1,13 @@@model ProductModel.ProductAttributeValueModel+@{+ var area = ViewContext.RouteData.Values["area"]?.ToString();+}@{Layout = "";//page title- ViewBag.Title = Loc["Admin.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"];+ ViewBag.Title = Loc[$"{Scope.ResourceKeyPrefix}.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"];}-<form id="ProductAttributeValueCreatePopup" asp-area="@Constants.AreaAdmin" asp-controller="Product" asp-action="ProductAttributeValueCreatePopup" method="post"+<form id="ProductAttributeValueCreatePopup" asp-area="@area" asp-controller="Product" asp-action="ProductAttributeValueCreatePopup" method="post"asp-route-ProductId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductId"])"asp-route-productAttributeMappingId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductAttributeMappingId"])"asp-route-btnId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["btnId"])"@@ -16,7 +19,7 @@<div class="x_title"><div class="caption"><i class="fa fa-cube"></i>- @Loc["Admin.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"]+ @Loc[$"{Scope.ResourceKeyPrefix}.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"]</div></div><div class="x_content form">diff --git a/src/Web/Grand.Web.Store/Areas/Store/Views/Product/ProductAttributeValueCreatePopup.cshtml b/src/Web/Grand.Web.Store/Areas/Store/Views/Product/ProductAttributeValueCreatePopup.cshtmldeleted file mode 100644index 73afd065a..000000000--- a/src/Web/Grand.Web.Store/Areas/Store/Views/Product/ProductAttributeValueCreatePopup.cshtml+++ /dev/null@@ -1,59 +0,0 @@-@model ProductModel.ProductAttributeValueModel-@{- Layout = "";- //page title- ViewBag.Title = Loc["Admin.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"];-}-<form id="ProductAttributeValueCreatePopup" asp-area="@Constants.AreaStore" asp-controller="Product" asp-action="ProductAttributeValueCreatePopup" method="post"- asp-route-ProductId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductId"])"- asp-route-productAttributeMappingId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductAttributeMappingId"])"- asp-route-btnId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["btnId"])"- asp-route-formId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["formId"])">-- <div class="row">- <div class="col-md-12">- <div class="x_panel light form-fit">- <div class="x_title">- <div class="caption">- <i class="fa fa-cube"></i>- @Loc["Admin.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"]- </div>- </div>- <div class="x_content form">- <partial name="Partials/CreateOrUpdateProductAttributeValue" model="Model"/>- </div>- </div>- </div>- </div>- <script>- $("#ProductAttributeValueCreatePopup").submit(function (e) {- e.preventDefault();- var form = $(this);- var url = form.attr('action');- $.ajax({- type: "POST",- url: url,- data: form.serialize(),- success: function (data) {- if (data == "") {- $.magnificPopup.instance.close();- $('#btnRefreshProductAttributesValues').attr('data-id', '@Model.ProductAttributeMappingId');- $('#btnRefreshProductAttributesValues').click();- } else {- $.magnificPopup.open({- items: {- src: data,- type: 'inline'- },- callbacks: {- open: function () {- $('.mfp-wrap').removeAttr('tabindex');- }- }- });- }- }- });- });- </script>-</form>\ No newline at end of filediff --git a/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Product/ProductAttributeValueCreatePopup.cshtml b/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Product/ProductAttributeValueCreatePopup.cshtmldeleted file mode 100644index 9e3cff0d9..000000000--- a/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Product/ProductAttributeValueCreatePopup.cshtml+++ /dev/null@@ -1,59 +0,0 @@-@model ProductModel.ProductAttributeValueModel-@{- Layout = "";- //page title- ViewBag.Title = Loc["Vendor.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"];-}-<form id="ProductAttributeValueCreatePopup" asp-area="@Constants.AreaVendor" asp-controller="Product" asp-action="ProductAttributeValueCreatePopup" method="post"- asp-route-ProductId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductId"])"- asp-route-productAttributeMappingId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["ProductAttributeMappingId"])"- asp-route-btnId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["btnId"])"- asp-route-formId="@HtmlExtensions.HtmlEncodeSafe(Context.Request.Query["formId"])">-- <div class="row">- <div class="col-md-12">- <div class="x_panel light form-fit">- <div class="x_title">- <div class="caption">- <i class="fa fa-cube"></i>- @Loc["Vendor.Catalog.Products.ProductAttributes.Attributes.Values.AddNew"]- </div>- </div>- <div class="x_content form">- <partial name="Partials/CreateOrUpdateProductAttributeValue" model="Model"/>- </div>- </div>- </div>- </div>- <script>- $("#ProductAttributeValueCreatePopup").submit(function (e) {- e.preventDefault();- var form = $(this);- var url = form.attr('action');- $.ajax({- type: "POST",- url: url,- data: form.serialize(),- success: function (data) {- if (data == "") {- $.magnificPopup.instance.close();- $('#btnRefreshProductAttributesValues').attr('data-id', '@Model.ProductAttributeMappingId');- $('#btnRefreshProductAttributesValues').click();- } else {- $.magnificPopup.open({- items: {- src: data,- type: 'inline'- },- callbacks: {- open: function () {- $('.mfp-wrap').removeAttr('tabindex');- }- }- });- }- }- });- });- </script>-</form>\ No newline at end of file