Browse Source

处理购物车删除问题

wangcz 7 years ago
parent
commit
e7abb41398
1 changed files with 2 additions and 1 deletions
  1. 2 1
      pages/mobile/center/user/cart/index.vue

+ 2 - 1
pages/mobile/center/user/cart/index.vue

@@ -358,7 +358,8 @@
         }
       },
       doDelete (idArr, successStr) {
-        this.$http.delete(`/trade/cart/deleteById?ids=${JSON.stringify(idArr)}`).then(res => {
+        // this.$http.delete(`/trade/cart/deleteById?ids=${encodeURIComponent(JSON.stringify(idArr))}`).then(res => {
+        this.$http.delete(`/trade/cart/deleteById?ids=%5B${idArr}%5D`).then(res => {
           this.isChange = true
           this.page = 1
           this.reloadList()