[shopping cart] show ok icon in update button
This commit is contained in:
parent
c2a352711f
commit
cd6dcacc6e
@ -43,11 +43,11 @@
|
||||
<button class="btn btn-primary">
|
||||
<i class="icon-shopping-cart"></i> Add to Cart</button>
|
||||
</div>
|
||||
<div id="item-update-cart" class="input-group col-lg-6" style="display: none;">
|
||||
<div id="item-update-cart" class="input-group col-lg-4" style="display: none;">
|
||||
<input type="text">
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-primary">
|
||||
<i class="icon-shopping-cart"></i> Update</button>
|
||||
<i class="icon-ok"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -51,7 +51,6 @@ $.extend(wn.cart, {
|
||||
bind_events: function() {
|
||||
// bind update button
|
||||
$(document).on("click", ".item-update-cart button", function() {
|
||||
console.log("click!");
|
||||
var item_code = $(this).attr("data-item-code");
|
||||
wn.cart.update_cart({
|
||||
item_code: item_code,
|
||||
@ -84,7 +83,7 @@ $.extend(wn.cart, {
|
||||
'{% include "app/website/templates/html/product_missing_image.html" %}';
|
||||
|
||||
if(!doc.web_short_description) doc.web_short_description = doc.description;
|
||||
|
||||
|
||||
$(repl('<div class="row">\
|
||||
<div class="col col-lg-9 col-sm-9">\
|
||||
<div class="row">\
|
||||
@ -101,8 +100,7 @@ $.extend(wn.cart, {
|
||||
data-item-code="%(item_code)s">\
|
||||
<div class="input-group-btn">\
|
||||
<button class="btn btn-primary" data-item-code="%(item_code)s">\
|
||||
<i class="icon-shopping-cart"></i>\
|
||||
<span class="hidden-sm-inline"> Update</span></button>\
|
||||
<i class="icon-ok"></i></button>\
|
||||
</div>\
|
||||
</div>\
|
||||
<p style="margin-top: 10px;">at %(formatted_rate)s</p>\
|
||||
@ -113,6 +111,8 @@ $.extend(wn.cart, {
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
return;
|
||||
|
||||
if(Object.keys(wn.cart.get_cart()).length) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user