...
|
...
|
@@ -10,6 +10,7 @@ var Stepper = require('./cart/stepper'); |
|
|
|
|
|
$(function() {
|
|
|
var $this;
|
|
|
var editable = true;
|
|
|
|
|
|
// 关闭info-bar
|
|
|
$('.info-bar .close').on('click', function() {
|
...
|
...
|
@@ -60,16 +61,25 @@ $(function() { |
|
|
}).delegate('.editable', 'click', function() {
|
|
|
$this = $(this);
|
|
|
|
|
|
if (editable) {
|
|
|
editable = false;
|
|
|
|
|
|
// 编辑商品颜色和属性
|
|
|
Cart.editColorOrSize(
|
|
|
$this.attr('data-productId'),
|
|
|
$this.attr('data-productSkn'),
|
|
|
$this.find('.default-color').text(),
|
|
|
$this.find('.default-size').text());
|
|
|
$this.find('.default-size').text(), function() {
|
|
|
editable = true;
|
|
|
});
|
|
|
|
|
|
$('body').on('click', function() {
|
|
|
$('body').off('click').on('click', function() {
|
|
|
if ($('.edit-color-size').length) {
|
|
|
$('.edit-color-size').remove();
|
|
|
editable = true;
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
}).delegate('#checkout_btn', 'click', function(e) {
|
|
|
e.preventDefault();
|
|
|
if ($('.chk-group').length) {
|
...
|
...
|
|