fix: Hide button and cart after success

This commit is contained in:
Faris Ansari 2019-05-01 14:56:50 +05:30
parent 5f1eebec16
commit 358329d7df

View File

@ -162,6 +162,8 @@ $.extend(shopping_cart, {
.html(msg || frappe._("Something went wrong!"))
.toggle(true);
} else {
$('.cart-container table').hide();
$(btn).hide();
window.location.href = '/orders/' + encodeURIComponent(r.message);
}
}
@ -185,6 +187,8 @@ $.extend(shopping_cart, {
.html(msg || frappe._("Something went wrong!"))
.toggle(true);
} else {
$('.cart-container table').hide();
$(btn).hide();
window.location.href = '/quotations/' + encodeURIComponent(r.message);
}
}