|
@@ -46,26 +46,26 @@
|
|
|
</view>
|
|
|
<view class="list-body">
|
|
|
<uni-grid :column="4" :highlight="true" :show-border="false" :square="false" @change="e=>openDataList(e)">
|
|
|
- <uni-grid-item v-if="hasBalaceAuth">
|
|
|
- <view class="grid-item-box" :index="0">
|
|
|
+ <uni-grid-item v-if="hasBalaceAuth" :index="0" :key="0">
|
|
|
+ <view class="grid-item-box">
|
|
|
<text class="value">{{Number(storeAccount.rechargeBalance).toFixed(2)}}</text>
|
|
|
<text class="text">充值余额</text>
|
|
|
</view>
|
|
|
</uni-grid-item>
|
|
|
- <uni-grid-item v-if="hasBalaceAuth">
|
|
|
- <view class="grid-item-box" :index="1">
|
|
|
+ <uni-grid-item v-if="hasBalaceAuth" :index="1" :key="1">
|
|
|
+ <view class="grid-item-box">
|
|
|
<text class="value">{{Number(storeAccount.giveBalance).toFixed(2)}}</text>
|
|
|
<text class="text">抵扣余额</text>
|
|
|
</view>
|
|
|
</uni-grid-item>
|
|
|
- <uni-grid-item>
|
|
|
- <view class="grid-item-box" :index="2" v-if="$hasPermissions('M_couponList_mini')">
|
|
|
+ <uni-grid-item :index="2" :key="2">
|
|
|
+ <view class="grid-item-box" v-if="$hasPermissions('M_couponList_mini')">
|
|
|
<text class="value">{{hasShelf?couponCount:0}}</text>
|
|
|
<text class="text">优惠券</text>
|
|
|
</view>
|
|
|
</uni-grid-item>
|
|
|
- <uni-grid-item>
|
|
|
- <view class="grid-item-box" :index="3" v-if="hasLogin&&hasRedPacket&&hasShelf">
|
|
|
+ <uni-grid-item :index="3" :key="3">
|
|
|
+ <view class="grid-item-box" v-if="hasLogin&&hasRedPacket&&hasShelf">
|
|
|
<text class="value">{{redPackCount}}</text>
|
|
|
<text class="text">红包</text>
|
|
|
</view>
|
|
@@ -120,7 +120,7 @@
|
|
|
import UniStatusBar from '@/components/uni-status-bar/uni-status-bar.vue'
|
|
|
import { queryQplsConfig,getProductfindByScanCode } from '@/api/shelf.js'
|
|
|
import { findUserReward } from '@/api/rewardRule.js'
|
|
|
- import { ticketQueryCount } from '@/api/user.js'
|
|
|
+ import { ticketQueryCount, storeAccount } from '@/api/user.js'
|
|
|
import { clickTab, toLogin } from "@/utils/index.js"
|
|
|
export default {
|
|
|
components: {
|
|
@@ -372,12 +372,21 @@
|
|
|
if(!this.hasLogin){
|
|
|
this.hidePromoTab()
|
|
|
}
|
|
|
+ // 抵扣余额,充值余额
|
|
|
+ this.getStoreAccount()
|
|
|
},
|
|
|
// 页面卸载
|
|
|
onUnload() {
|
|
|
uni.$off('refashProm')
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 抵扣余额
|
|
|
+ getStoreAccount(){
|
|
|
+ const data = this.$store.state.vuex_storeShelf
|
|
|
+ storeAccount({storeSn:data.storeSn}).then(res => {
|
|
|
+ this.$store.state.vuex_storeAccount = res.data
|
|
|
+ })
|
|
|
+ },
|
|
|
// 获取优惠券数量
|
|
|
getCouponCount(){
|
|
|
if(this.userInfo.sysUserFlag == '1'){
|
|
@@ -430,6 +439,7 @@
|
|
|
},
|
|
|
// 点击统计数据
|
|
|
openDataList(e){
|
|
|
+ console.log(e)
|
|
|
const path = [
|
|
|
'/pagesB/accountBalance/accountBalance',
|
|
|
'/pagesB/accountBalance/accountBalance',
|