|
@@ -97,7 +97,7 @@
|
|
|
console.log(res)
|
|
|
if(res.status == 200){
|
|
|
this.goodContent = res.data
|
|
|
- this.goldLimit = res.data.goodsType.goldLimit
|
|
|
+ this.goldLimit = res.data.goodsType.goldLimit || 0
|
|
|
let arr=res.data.images.split(',')
|
|
|
arr.map(item => {
|
|
|
this.imageList.push({image:item})
|
|
@@ -113,7 +113,9 @@
|
|
|
})
|
|
|
addGoodsToCart(item).then(res => {
|
|
|
if(res.status == 200){
|
|
|
- // 刷新购物车
|
|
|
+ // 刷新购物车数据
|
|
|
+ uni.$emit('getCartList')
|
|
|
+ // 刷新购物车数量
|
|
|
if(!item.hasCunzai){
|
|
|
this.$store.state.vuex_cartNums = this.$store.state.vuex_cartNums + 1
|
|
|
}
|