调整个人中心页面,会议中心页面,充值页面

This commit is contained in:
2025-09-26 17:57:14 +08:00
parent a39c9f4d72
commit 905d5404f6
20 changed files with 1397 additions and 230 deletions

View File

@@ -22,7 +22,7 @@
<up-gap height="26rpx" bg-color="#F9F9F9"></up-gap>
<!-- <view class="my_item my_assets" @click="Myassets"> -->
<view class="my_item my_assets" >
<view class="my_item my_assets">
<view class="my_item_title u-m-t-12">我的资产</view>
<view class="amount">
<view class="u-flex u-flex-between u-m-t-20">
@@ -33,25 +33,27 @@
</image>
<text class="color-333 font-14 u-m-l-20">储值</text>
</view>
<view class="u-flex color-666">
<text class="font-12 u-m-r-4">3家店</text>
<view class="u-flex color-666" @click="toChargeList">
<text class="font-12 u-m-r-4">{{rechargeList.length}}家店</text>
<up-icon name="arrow-down" color="#666" size="12px"></up-icon>
</view>
</view>
<view class="card-list">
<view class="card-list-item" v-for="(item,index) in 3" :key="index">
<up-image radius="20rpx" width="182rpx" height="182rpx"></up-image>
<view class="card-list-item" v-for="(item,index) in rechargeList" :key="index"
@click="toCharge(item)">
<up-image radius="20rpx" width="182rpx" height="182rpx" :src="item.logo"> </up-image>
<view class="info text-center">
<view class="color-333 u-m-t-14 ">
<text class="font-10">¥</text>
<text class="font-16 font-700 ">9999.99</text>
<text class="font-16 font-700 ">{{item.amount}}</text>
</view>
<view class="font-12 color-666">这里是店铺名称</view>
<view class="font-12 color-666 u-line-1">{{item.shopName}}</view>
</view>
</view>
<view class="u-flex u-flex-column u-flex-center">
<view class="u-flex u-flex-column u-flex-center" style="width: 12px;" v-if="rechargeList.length"
@click="toChargeList">
<view class="text-center color-333 font-12">查看全部</view>
</view>
</view>
@@ -63,25 +65,22 @@
</image>
<text class="color-333 font-14 u-m-l-20">会员</text>
</view>
<view class="u-flex color-666">
<text class="font-12 u-m-r-4">3家店</text>
<view class="u-flex color-666" @click="tomemberList">
<text class="font-12 u-m-r-4">{{memberList.length}}家店</text>
<up-icon name="arrow-down" color="#666" size="12px"></up-icon>
</view>
</view>
<view class="card-list">
<view class="card-list-item" v-for="(item,index) in 3" :key="index">
<up-image radius="20rpx" width="182rpx" height="182rpx"></up-image>
<view class="card-list-item" v-for="(item,index) in memberList" :key="index"
@click="tomember(item)">
<up-image radius="20rpx" width="182rpx" height="182rpx" :src="item.logo"></up-image>
<view class="info text-center">
<view class="color-333 u-m-t-14 ">
<text class="font-10">¥</text>
<text class="font-16 font-700 ">9999.99</text>
</view>
<view class="font-12 color-666">这里是店铺名称</view>
<view class="font-12 color-666 u-m-t-14 u-line-1">{{item.shopName}}</view>
</view>
</view>
<view class="u-flex u-flex-column u-flex-center">
<view class="u-flex u-flex-column u-flex-center" style="width: 12px;" v-if="memberList.length">
<view class="text-center color-333 font-12" @click="tomemberList">查看全部</view>
</view>
</view>
@@ -129,11 +128,15 @@
productStore
} from '@/stores/user.js';
import * as vipApi from '@/common/api/market/vip.js'
import * as rechargeApi from '@/common/api/market/recharge.js'
const store = productStore();
const myFunList = ref([{
name: "积分",
type: "score",
icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/points.png"
icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/points.png",
url: '/user/score/list'
},
{
name: "优惠券",
@@ -162,26 +165,32 @@
const userInfo = reactive({})
const ShopId = ref(uni.cache.get('shopId'))
function tomemberList(){
console.log('ShopId', uni.cache.get('shopId'))
function tomemberList() {
uni.navigateTo({
url:'/pages/user/member/list'
url: '/pages/user/member/list'
})
}
function tomember(item) {
uni.navigateTo({
url: '/user/vip/vip?shopId=' + item.shopId
})
}
const clickEvent = () => {
if (ShopId.value) {
if(!userInfo.isVip){
if (!userInfo.isVip) {
uni.navigateTo({
url: '/user/vip/buy-vip?shopId='+ShopId.value
url: '/user/vip/buy-vip?shopId=' + ShopId.value
})
}else{
} else {
uni.navigateTo({
url: '/user/vip/vip?shopId='+ShopId.value
url: '/user/vip/vip?shopId=' + ShopId.value
})
}
// if (userInfo.isVip == 0) {
@@ -216,7 +225,26 @@
}
}
function toCharge(item) {
uni.navigateTo({
url: '/pages/user/member/czzx?shopId=' + item.shopId
})
}
function toChargeList() {
uni.navigateTo({
url: '/pages/user/member/amount-list'
})
}
const clickTo = (item, index) => {
if (item.url) {
uni.navigateTo({
url:item.url
})
return
}
let shopId = null;
switch (item.type) {
case 'my_order':
@@ -267,9 +295,14 @@
break;
}
}
const memberList = ref([])
const rechargeList = ref([])
async function getData() {
const res = await vipApi.list()
console.log(res);
memberList.value = res.slice(0, 3);
const res1 = await rechargeApi.list()
rechargeList.value = res1.slice(0, 3);
}
onShow(() => {
store.actionsAPIuser()
@@ -450,9 +483,11 @@
.card-list-item {
max-width: 182rpx;
box-shadow: 8rpx 8rpx 32rpx 0 #0b18390f;
border-radius: 0 0 20rpx 20rpx;
.info {
padding-bottom: 16rpx;
border-radius: 0 0 20rpx 20rpx;
overflow: hidden;
}
}