Pārlūkot izejas kodu

修改商品规格后保持选中

junyuanz 4 gadi atpakaļ
vecāks
revīzija
6034c34151
2 mainītis faili ar 2 papildinājumiem un 2 dzēšanām
  1. 1 1
      pages/areacart/areacart.js
  2. 1 1
      pages/centcart/centcart.js

+ 1 - 1
pages/areacart/areacart.js

@@ -662,7 +662,7 @@ Page({
 		console.log(this.data.selectProject)
 		console.log(this.data.selectProjectItem)
 		itemdata['count']=1;
-		itemdata['IsBuy']=false;
+		itemdata['IsBuy']=this.data.cartList[itemindex].IsBuy;
 		itemdata['movex']=0;
 		itemdata['overtype']=true;
 		that.setData({

+ 1 - 1
pages/centcart/centcart.js

@@ -697,7 +697,7 @@ Page({
   		console.log(this.data.selectProject)
   		console.log(this.data.selectProjectItem)
   		itemdata['count']=1;
-  		itemdata['IsBuy']=false;
+  		itemdata['IsBuy']=this.data.cartList[itemindex].IsBuy;
   		itemdata['movex']=0;
   		itemdata['overtype']=true;
   		that.setData({