Adding a quantitative part to _ProductBox.cshtml in views / Catalog in nopcommerce2.2

In nopcommerce2.2, where the mvc framework is used, how can I add a quantitative part of a product to several products ie _ProductBox.cshtml? In fact, when I go to a single product page, I will get a quantitative part. But I can’t transfer part of the quantity to a page with several products. How can i do this?

+5
source share
2 answers

I'm on 2.3, so this may be different from your version.

You will need to change a few things about _ProductBox.cshtml.

, , _ProductVariantAddToCart.cshtml.

@if (!Model.DisableBuyButton || !Model.DisableWishlistButton)
{
    @Html.LabelFor(model => model.EnteredQuantity)<text>:</text> 
    @Html.TextBoxFor(model => model.EnteredQuantity, new { style = "Width: 40px;" })
}

, _ProductBox.cshtml JS GET AddControlCard ControlCartCart. , _ProductVariantAddToCart.cshtml AddToCartProduct Catalog. , .

, AddProductToCart ShoppingCartController, JS , .

+2

All Articles