Bulk Edit Products

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 years ago
Can I add a field to the Bulk Edit Products Page? I want to edit all of the products that we sell with their weights - can I add Weight as a field to the Bulk Edit Products Page as this will make my job a lot easier?
Thanks.
7 years ago
What you want requires customization work. A probably better way is to export to Excel the products with just the columns you want to update; update them and re-import it
5 years ago
Sederholm wrote:
Can I add a field to the Bulk Edit Products Page? I want to edit all of the products that we sell with their weights - can I add Weight as a field to the Bulk Edit Products Page as this will make my job a lot easier?
Thanks.


This is very easy to do.

Firstly, open Presentation/Nop.Web/Areas/Admin/Controllers/ProductController.cs and go to the method BulkEditSelect. There, update the productModel variable to this one:

var productModel = new BulkEditProductModel
{
    Id = x.Id,
    Name = x.Name,
    Sku = x.Sku,
    Weight = x.Weight,
    OldPrice = x.OldPrice,
    Price = x.Price,
    ManageInventoryMethod = x.ManageInventoryMethod.GetLocalizedEnum(_localizationService, _workContext.WorkingLanguage.Id),
    StockQuantity = x.StockQuantity,
    Published = x.Published
};


Then, in the same file, go to the BulkEditUpdate method, and update the code block to this ():

product.Name = pModel.Name;
product.Sku = pModel.Sku;
product.Weight = pModel.Weight;
product.Price = pModel.Price;
product.OldPrice = pModel.OldPrice;
product.StockQuantity = pModel.StockQuantity;
product.Published = pModel.Published;
product.UpdatedOnUtc = DateTime.UtcNow;
_productService.UpdateProduct(product);


Now, finally open Presentation/Nop.Web/Areas/Admin/Views/Product/BulkEdit.cshtml.

Under fields (line 135), add this line:

Weight: { editable: true, type: "number" },


Then put this line between 'Sku' and 'Price' tabs (line 193):

{
    field: "Weight",
    title: "@T("Admin.Catalog.Products.Fields.Weight")",
    width: 150,
    editor: function (container, options) {
        $('<input name="' + options.field + '"/>')
            .appendTo(container)
            .kendoNumericTextBox({
                format: "{0:n4}",
                decimals: 4
            });
    }
},


And you can do this for any kind of product feature.
3 years ago
You can use this plugin and enjoy it!
products bulk editor
2 years ago
i think plugin more fir to the solution
this  Plugin allows admin user to bulk edit products with all major product fields. (90%  of the fileds ) include bulk edit for category, tags , manufacture ....

The plugin also provides a stock report by the filter (category, Manufacturer, Product type) and exports it to excel.
Plugin allows admin user to bulk edit products with all major product fields. The plugin also provides a stock report by the filter (category, Manufacturer, Product type) and exports it to excel.
https://www.nopcommerce.com/en/bulk-product-edit-and-stock-report-filterd
https://nopshop.co.il/bulk-edit-product
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.