crm-uniapp/pages/msg/index.vue
2024-10-09 16:24:04 +08:00

69 lines
2.0 KiB
Vue

<template>
<uv-navbar
:fixed="false"
@leftClick="$onClickLeft"
bgColor="#09b4f1"
>
<template v-slot:left>
<uv-icon name="arrow-left" size="19" color="#ffffff"></uv-icon>
</template>
<template v-slot:center>
<text style="color:#ffffff">{{title}}</text>
</template>
</uv-navbar>
<view class="bg-white">
<uv-cell-group>
<uv-cell icon="/static/images/16.png" title="待办事项" label="待办事项消息提现" iconStyle="height:70rpx;width:70rpx;margin-right:10rpx">
<template v-slot:right-icon>
<view class="flex align-center" @click="gopage('/pages/components/pages/msg/wait')">
<uv-badge type="error" max="99" :value="waitCount"></uv-badge>
<uv-icon size="30rpx" name="arrow-right"></uv-icon>
</view>
</template>
</uv-cell>
<uv-cell icon="/static/images/15.png" title="审批管理" label="审批消息提现" iconStyle="height:70rpx;width:70rpx;margin-right:10rpx">
<template v-slot:right-icon>
<view class="flex align-center" @click="gopage('/pages/components/pages/msg/exam')">
<uv-badge type="error" max="99" :value="checkCount"></uv-badge>
<uv-icon size="30rpx" name="arrow-right"></uv-icon>
</view>
</template>
</uv-cell>
</uv-cell-group>
</view>
</template>
<script setup>
import {
ref,
computed
} from 'vue'
import { useMainStore } from '@/store/store'
import { storeToRefs } from 'pinia'
import { onLoad,onShow} from '@dcloudio/uni-app'
const main = useMainStore()
const { indexCount } = storeToRefs(main)
const title = ref('消息')
const cart = ref([])
const uToast = ref()
const waitCount = ref(0)
const checkCount = ref(0)
onShow(() => {
waitCount.value = indexCount.value.followBusinessCount + indexCount.value.followCluesCount + indexCount.value.followCustomerCount
checkCount.value = indexCount.value.contractCheckCount + indexCount.value.invoiceCheckCount + indexCount.value.receivablesCheckCount
})
const gopage = (url) => {
uni.navigateTo({
url
})
}
</script>
<style lang="scss" scoped>
</style>