Commit e79b72133954f7c2f35ec8d7649740ab111c1c8b
1 parent
34703a7672
Exists in
master
加购更新
Showing
1 changed file
with
3 additions
and
5 deletions
Show diff stats
src/pages/details/details.vue
| ... | ... | @@ -420,8 +420,8 @@ export default { |
| 420 | 420 | }) |
| 421 | 421 | }, |
| 422 | 422 | // 加入购物车 |
| 423 | - addCart (mpId, num, checkedSKU, skId,price) { | |
| 424 | - const addCartList = {} | |
| 423 | + addCart (mpId, num, checkedSKU, skId, price) { | |
| 424 | + const addCartList = {} | |
| 425 | 425 | addCartList.mp_id = mpId |
| 426 | 426 | addCartList.sk_id = skId |
| 427 | 427 | addCartList.num = num |
| ... | ... | @@ -437,9 +437,7 @@ export default { |
| 437 | 437 | }) |
| 438 | 438 | } |
| 439 | 439 | // 再次请求购物车接口,实现实时更新 |
| 440 | - store.dispatch('cart/getCartList', { | |
| 441 | - uid: this.$store.state.user.userInfo.uid, | |
| 442 | - }) | |
| 440 | + store.dispatch('details/getCartNumber') | |
| 443 | 441 | }) |
| 444 | 442 | }, |
| 445 | 443 | }, |
| ... | ... |