|
|
@ -145,8 +145,6 @@ |
|
|
|
import noMore from '@/pages/classify/no-more/no-more.vue' |
|
|
|
import noMore from '@/pages/classify/no-more/no-more.vue' |
|
|
|
import wybPopup from '@/components/wyb-popup/wyb-popup.vue' |
|
|
|
import wybPopup from '@/components/wyb-popup/wyb-popup.vue' |
|
|
|
import cartChoose from '@/pages/classify/cart-choose/cart-choose.vue' |
|
|
|
import cartChoose from '@/pages/classify/cart-choose/cart-choose.vue' |
|
|
|
// import dataList from '@/components/dataList/dataList.vue' |
|
|
|
|
|
|
|
// import uniNumberBox from '@/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue' |
|
|
|
|
|
|
|
import { findGoodsSkuByGoodsId,getShoppingCartList } from '@/Utils/physicalObject.js' |
|
|
|
import { findGoodsSkuByGoodsId,getShoppingCartList } from '@/Utils/physicalObject.js' |
|
|
|
import uniBadge from '@/components/uni-badge/components/uni-badge/uni-badge.vue' |
|
|
|
import uniBadge from '@/components/uni-badge/components/uni-badge/uni-badge.vue' |
|
|
|
const app = getApp(); |
|
|
|
const app = getApp(); |
|
|
@ -198,9 +196,7 @@ |
|
|
|
this.refreshCartNum(); |
|
|
|
this.refreshCartNum(); |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
mounted(){ |
|
|
|
|
|
|
|
console.log("挂载了") |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
props: { |
|
|
|
props: { |
|
|
|
propData: { |
|
|
|
propData: { |
|
|
|
type: Array, |
|
|
|
type: Array, |
|
|
@ -280,16 +276,7 @@ |
|
|
|
refreshCartNum(){ |
|
|
|
refreshCartNum(){ |
|
|
|
getShoppingCartList().then( res=>{ |
|
|
|
getShoppingCartList().then( res=>{ |
|
|
|
if (res.return_code == '000000') { |
|
|
|
if (res.return_code == '000000') { |
|
|
|
this.cartNum = res.return_data.length; |
|
|
|
this.cartNum = res.return_data.length; |
|
|
|
// uni.setStorage({ |
|
|
|
|
|
|
|
// key:'cartNum', //存储到本地的名字 |
|
|
|
|
|
|
|
// data:res.return_data.length, //存储的数据 |
|
|
|
|
|
|
|
// success(){ |
|
|
|
|
|
|
|
// console.log('存储成功') |
|
|
|
|
|
|
|
// console.log(app.globalData.cartNum,"this.cartNum") |
|
|
|
|
|
|
|
// } |
|
|
|
|
|
|
|
// }) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
uni.showToast({ |
|
|
|
uni.showToast({ |
|
|
|
title: res.return_msg, |
|
|
|
title: res.return_msg, |
|
|
|