Using popup cart
1. Trong data .NET cần EnableCartPopup là true
2. Trong file layout đảm bảo có
@ { Html.RenderPartial("_MetaBodys");}
3. Thêm sự kiện cho button MUA
file _VariantContent.cshtml
onclick="addToPopupCart({ productVariantId: '@Model.Id', name: '@Model.Name', price: '@Model.Price', image: '@imgUrl', quantity: '1' })" |
file _ProductItem.cshtml
onclick="addToPopupCart({ productVariantId: '@Model.DefaultProductVariant.Id', name: '@Model.Name', price: '@Model.DefaultProductVariant.Price', image: '@imgUrl', quantity: '1' })" |
Gửi bình luận của bạn
Đăng nhập để bình luận