From eab5be111018b2615844e94aa2bf6ee6b7e9dbae Mon Sep 17 00:00:00 2001 From: Shivam Mishra Date: Tue, 20 Aug 2019 19:31:54 +0530 Subject: [PATCH] fix: shopping cart item availability --- erpnext/templates/includes/product_page.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/templates/includes/product_page.js b/erpnext/templates/includes/product_page.js index 65949bb18c..90a1d862c3 100644 --- a/erpnext/templates/includes/product_page.js +++ b/erpnext/templates/includes/product_page.js @@ -32,7 +32,7 @@ frappe.ready(function() { if(r.message.product_info.in_stock===0) { $(".item-stock").html("
{{ _("Not in stock") }}
"); } - else if(r.message.product_info.in_stock===1) { + else if(r.message.product_info.in_stock===1 && r.message.cart_settings.show_stock_availability) { var qty_display = "{{ _("In stock") }}"; if (r.message.product_info.show_stock_qty) { qty_display += " ("+r.message.product_info.stock_qty+")";