Skip to content

Commit a6d70cc

Browse files
Admin panel - remove AddSpecificationAttributeModel from ProductModel
1 parent 4cb887b commit a6d70cc

File tree

3 files changed

+1
-7
lines changed

3 files changed

+1
-7
lines changed

src/Web/Grand.Web.Admin/Mapper/ProductProfile.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ public ProductProfile()
2525
.ForMember(dest => dest.AvailableProductAttributes, mo => mo.Ignore())
2626
.ForMember(dest => dest.AddPictureModel, mo => mo.Ignore())
2727
.ForMember(dest => dest.ProductPictureModels, mo => mo.Ignore())
28-
.ForMember(dest => dest.AddSpecificationAttributeModel, mo => mo.Ignore())
2928
.ForMember(dest => dest.CopyProductModel, mo => mo.Ignore())
3029
.ForMember(dest => dest.ProductWarehouseInventoryModels, mo => mo.Ignore())
3130
.ForMember(dest => dest.IsLoggedInAsVendor, mo => mo.Ignore())

src/Web/Grand.Web.Admin/Models/Catalog/ProductModel.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ public ProductModel()
2727
AvailableProductAttributes = new List<SelectListItem>();
2828
AvailableUnits = new List<SelectListItem>();
2929
AddPictureModel = new ProductPictureModel();
30-
AddSpecificationAttributeModel = new AddProductSpecificationAttributeModel();
3130
ProductWarehouseInventoryModels = new List<ProductWarehouseInventoryModel>();
3231
CalendarModel = new GenerateCalendarModel();
3332
}
@@ -404,8 +403,7 @@ public ProductModel()
404403
//discounts
405404
public List<DiscountModel> AvailableDiscounts { get; set; }
406405
public string[] SelectedDiscountIds { get; set; }
407-
//add specification attribute model
408-
public AddProductSpecificationAttributeModel AddSpecificationAttributeModel { get; set; }
406+
409407
//multiple warehouses
410408
[GrandResourceDisplayName("Admin.Catalog.Products.ProductWarehouseInventory")]
411409
public IList<ProductWarehouseInventoryModel> ProductWarehouseInventoryModels { get; set; }

src/Web/Grand.Web.Admin/Services/ProductViewModelService.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -601,9 +601,6 @@ public virtual async Task PrepareProductModel(ProductModel model, Product produc
601601
foreach (var un in units)
602602
model.AvailableUnits.Add(new SelectListItem { Text = un.Name, Value = un.Id.ToString(), Selected = product != null && un.Id == product.UnitId });
603603

604-
//default specs values
605-
model.AddSpecificationAttributeModel.ShowOnProductPage = true;
606-
607604
//discounts
608605
model.AvailableDiscounts = (await _discountService
609606
.GetAllDiscounts(DiscountType.AssignedToSkus, storeId: _workContext.CurrentCustomer.StaffStoreId, showHidden: true))

0 commit comments

Comments
 (0)