Authored by 邱骏

购物车编辑时增减数量不显示预购商品提示,单独更新某个商品数量返回时正确更改购物车中的数量

@@ -317,6 +317,7 @@ let goodObj = { @@ -317,6 +317,7 @@ let goodObj = {
317 }); 317 });
318 }, 318 },
319 getSelectGoodData(eles, selectAll) { 319 getSelectGoodData(eles, selectAll) {
  320 +
320 return Array.from(eles.map((i, ele) => { 321 return Array.from(eles.map((i, ele) => {
321 let $this = $(ele), 322 let $this = $(ele),
322 $good = $this.closest('.good-item'), 323 $good = $this.closest('.good-item'),
@@ -393,7 +394,7 @@ let goodObj = { @@ -393,7 +394,7 @@ let goodObj = {
393 if (res && res.code === 200) { 394 if (res && res.code === 200) {
394 $(e.delegateTarget).data('id', result.sku.skuId); 395 $(e.delegateTarget).data('id', result.sku.skuId);
395 if (!$(e.delegateTarget).find('.chk.select').hasClass('checked')) { 396 if (!$(e.delegateTarget).find('.chk.select').hasClass('checked')) {
396 - self.selectGood($(e.delegateTarget).find('.chk.select')); 397 + self.selectGood($(e.delegateTarget).find('.chk.select'), false);
397 } else { 398 } else {
398 self.handle.refreshPage(); 399 self.handle.refreshPage();
399 } 400 }
@@ -473,7 +474,7 @@ let goodObj = { @@ -473,7 +474,7 @@ let goodObj = {
473 474
474 if (!$(e.delegateTarget).find('.chk.select').hasClass('checked') && goodNum <= max) { 475 if (!$(e.delegateTarget).find('.chk.select').hasClass('checked') && goodNum <= max) {
475 self.handle.posting = false; 476 self.handle.posting = false;
476 - self.selectGood($(e.delegateTarget).find('.chk.select')); 477 + self.selectGood($(e.delegateTarget).find('.chk.select'), false);
477 } else { 478 } else {
478 self.handle.refreshPage().then(() => { 479 self.handle.refreshPage().then(() => {
479 self.handle.posting = false; 480 self.handle.posting = false;