This commit is contained in:
2025-12-05 08:59:05 +08:00
6 changed files with 21 additions and 11 deletions

View File

@@ -59,14 +59,16 @@ const orderType = ref<string>('')
onLoad(async () => {
try {
// 获取商品列表
uni.$on('selectedGoods', (data: IOrderGoods) => {
await uni.$on('selectedGoods', async (data: IOrderGoods) => {
// 获取用户信息
await getUserInfo()
// 处理商品数据
console.log('监听到传入的商品数据:', data)
isLengthen.value = data.state !== null
orderType.value = data.orderType || ''
goodsList.value = [ data ]
})
// 获取用户信息
getUserInfo()
} catch (error) {
console.error('解析商品数据失败:', error)
uni.showToast({

View File

@@ -86,7 +86,7 @@
const sysStore = useSysStore()
// 默认头像
const defaultAvatar = '/static/home_icon.png'
const defaultAvatar = '/static/logo.png'
// 用户信息
const userInfo = computed(() => userStore.userInfo)

View File

@@ -26,7 +26,6 @@
:class="{ 'package-card--popular': vip.isRecommend }"
v-for="(vip, index) in vipList"
:key="index"
@click="selectPackage(vip)"
>
<view class="package-header">
<view class="package-title-wrapper">