|
|
@ -1,10 +1,19 @@ |
|
|
|
<template> |
|
|
|
<!-- 灵动岛占位区域 - 始终存在但控制可见性 --> |
|
|
|
<view class="dynamic-island-placeholder" :class="{ visible: isScrolled }" :style="{ height: 216 + 'rpx' }"> |
|
|
|
<view class="dynamic-island" :class="{ |
|
|
|
<view |
|
|
|
class="dynamic-island-placeholder" |
|
|
|
:class="{ visible: isScrolled }" |
|
|
|
:style="{ height: 216 + 'rpx' }" |
|
|
|
> |
|
|
|
<view |
|
|
|
class="dynamic-island" |
|
|
|
:class="{ |
|
|
|
compact: actualCompactState, |
|
|
|
fixed: isFixed, |
|
|
|
}" :style="{ top: isFixed ? fixedTopPosition + 'px' : 0 }" @click="handleToggle"> |
|
|
|
}" |
|
|
|
:style="{ top: isFixed ? fixedTopPosition + 'px' : 0 }" |
|
|
|
@click="handleToggle" |
|
|
|
> |
|
|
|
<!-- 展开状态 --> |
|
|
|
<view v-if="!actualCompactState" class="expanded-content"> |
|
|
|
<template> |
|
|
@ -14,19 +23,29 @@ |
|
|
|
<!-- 右侧:头像和链接 --> |
|
|
|
<view class="right-section"> |
|
|
|
<view class="avatar-container" @click="toWebView"> |
|
|
|
<image class="avatar" |
|
|
|
<image |
|
|
|
class="avatar" |
|
|
|
src="https://epic.js-dyyj.com/uploads/20250826/92b0a21e9125fc21ca294a408bf3508f.png" |
|
|
|
mode="aspectFill"></image> |
|
|
|
mode="aspectFill" |
|
|
|
></image> |
|
|
|
<view class="ai-label">智能体</view> |
|
|
|
</view> |
|
|
|
<view class="" |
|
|
|
style="display: flex;flex-direction: column;justify-content: space-between;height: 100%;"> |
|
|
|
<view |
|
|
|
class="" |
|
|
|
style=" |
|
|
|
display: flex; |
|
|
|
flex-direction: column; |
|
|
|
justify-content: space-between; |
|
|
|
height: 100%; |
|
|
|
" |
|
|
|
> |
|
|
|
<view class="profile-info"> |
|
|
|
<text class="profile-title">数字领航员</text> |
|
|
|
<text class="profile-name">EVITA</text> |
|
|
|
</view> |
|
|
|
<view class="platform-link"> |
|
|
|
<view class="link-text" @click="toDesInfo">交响介绍 >> |
|
|
|
<view class="link-text" @click="toDesInfo" |
|
|
|
>交响介绍 >> |
|
|
|
</view> |
|
|
|
<!-- <view class="link-text">DES广播 >></view> --> |
|
|
|
</view> |
|
|
@ -37,102 +56,168 @@ |
|
|
|
<!-- 左侧:欢迎信息 --> |
|
|
|
<view class="left-section"> |
|
|
|
<view class="welcome-message"> |
|
|
|
<view class="welcome-text">Hi! {{ |
|
|
|
<view class="welcome-text" |
|
|
|
>Hi! |
|
|
|
{{ |
|
|
|
userInfo && userInfo.token ? userInfo.nickname : "用户" |
|
|
|
}}欢迎回来~</view> |
|
|
|
}}欢迎回来~</view |
|
|
|
> |
|
|
|
</view> |
|
|
|
<view class="" style="font-size: 24rpx;font-weight: bold;color: #000000;"> |
|
|
|
<view |
|
|
|
class="" |
|
|
|
style="font-size: 24rpx; font-weight: bold; color: #000000" |
|
|
|
> |
|
|
|
查看您的交响数据文化资产行 |
|
|
|
</view> |
|
|
|
<view class="" |
|
|
|
style="display: flex;align-items: flex-end;justify-content: space-between;"> |
|
|
|
<view |
|
|
|
class="" |
|
|
|
style=" |
|
|
|
display: flex; |
|
|
|
align-items: flex-end; |
|
|
|
justify-content: space-between; |
|
|
|
" |
|
|
|
> |
|
|
|
<view class="" @click="toOrder"> |
|
|
|
<view class="stats-info"> |
|
|
|
<text |
|
|
|
class="stats-number">{{userInfo&&userInfo.unUseOrderQuantity||0}}</text> |
|
|
|
<text class="stats-number">{{ |
|
|
|
(userInfo && userInfo.unUseOrderQuantity) || 0 |
|
|
|
}}</text> |
|
|
|
<text class="stats-unit">个</text> |
|
|
|
</view> |
|
|
|
<view class="stats-label">交响权益行</view> |
|
|
|
</view> |
|
|
|
<div @click="toTime"> |
|
|
|
<view class="stats-info"> |
|
|
|
<text class="stats-number">{{userInfo&&userInfo.ipQuantity||0}}</text> |
|
|
|
<text class="stats-number">{{ |
|
|
|
(userInfo && userInfo.ipQuantity) || 0 |
|
|
|
}}</text> |
|
|
|
<text class="stats-unit">个</text> |
|
|
|
</view> |
|
|
|
<view class="stats-label">交响资产行</view> |
|
|
|
</div> |
|
|
|
<view class="middle-section"> |
|
|
|
<view class="time-reward-container" @click="toPoint"> |
|
|
|
<text class="time-reward-title" style="margin-bottom: 5rpx;">时间奖励</text> |
|
|
|
<text |
|
|
|
class="time-reward-title" |
|
|
|
style="margin-bottom: 5rpx" |
|
|
|
>时间奖励</text |
|
|
|
> |
|
|
|
<view class="time-reward-stats"> |
|
|
|
<text class="time-reward-number">{{ userInfo && userInfo.token ? userInfo.hourValue||0:0}}</text> |
|
|
|
<text class="time-reward-number">{{ |
|
|
|
userInfo && userInfo.token |
|
|
|
? userInfo.hourValue || 0 |
|
|
|
: 0 |
|
|
|
}}</text> |
|
|
|
<text class="time-reward-unit">点</text> |
|
|
|
</view> |
|
|
|
<text class="time-reward-label" style="font-weight: bold;">交响时间行</text> |
|
|
|
<text class="time-reward-label" style="font-weight: bold" |
|
|
|
>交响时间行</text |
|
|
|
> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</view> |
|
|
|
</template> |
|
|
|
<template v-if="styleType == 'timeShop'"> |
|
|
|
<view class="bottom-section"> |
|
|
|
<view class="" style="flex:1;"> |
|
|
|
<view class="" style="display: flex;"> |
|
|
|
<view class="time-reward-container" style="width: 200rpx;" @click="toPoint"> |
|
|
|
<view class="" style="flex: 1"> |
|
|
|
<view class="" style="display: flex"> |
|
|
|
<view |
|
|
|
class="time-reward-container" |
|
|
|
style="width: 200rpx" |
|
|
|
@click="toPoint" |
|
|
|
> |
|
|
|
<text class="time-reward-title">时间奖励</text> |
|
|
|
<view class="time-reward-stats"> |
|
|
|
<text class="time-reward-number">{{ |
|
|
|
userInfo && userInfo.token ? (userInfo.hourValue||0):0 |
|
|
|
userInfo && userInfo.token ? userInfo.hourValue || 0 : 0 |
|
|
|
}}</text> |
|
|
|
<text class="time-reward-unit">点</text> |
|
|
|
</view> |
|
|
|
<text class="time-reward-label" |
|
|
|
style="font-size: 24rpx;font-weight: bold;">交响时间行</text> |
|
|
|
<text |
|
|
|
class="time-reward-label" |
|
|
|
style="font-size: 24rpx; font-weight: bold" |
|
|
|
>交响时间行</text |
|
|
|
> |
|
|
|
</view> |
|
|
|
<view class=""> |
|
|
|
<view class="time-reward-number" style="font-size: 34rpx;"> |
|
|
|
<view class="time-reward-number" style="font-size: 34rpx"> |
|
|
|
{{ |
|
|
|
userInfo && userInfo.token ? userInfo.nickname : "用户" |
|
|
|
}} |
|
|
|
</view> |
|
|
|
<view class="time-reward-label" @click="toPoint" |
|
|
|
style="margin-top: 15rpx;font-weight: bold;font-size: 26rpx;"> |
|
|
|
积分:{{totalPoints||0}}<text |
|
|
|
<view |
|
|
|
class="time-reward-label" |
|
|
|
@click="toPoint" |
|
|
|
style=" |
|
|
|
margin-top: 15rpx; |
|
|
|
font-weight: bold; |
|
|
|
font-size: 26rpx; |
|
|
|
" |
|
|
|
> |
|
|
|
积分:{{ totalPoints || 0 |
|
|
|
}}<text |
|
|
|
@click.stop="pointDetail" |
|
|
|
style="color: #999999;font-size: 22rpx;margin-left: 10rpx;">积分获取规则</text> |
|
|
|
style=" |
|
|
|
color: #999999; |
|
|
|
font-size: 22rpx; |
|
|
|
margin-left: 10rpx; |
|
|
|
" |
|
|
|
>积分获取规则</text |
|
|
|
> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="" |
|
|
|
style="display: flex;align-items: center;font-size: 26rpx;font-weight: bold;display: flex;align-items: center;margin-top: 20rpx;"> |
|
|
|
<view class="" style="width: 200rpx;"> |
|
|
|
<view |
|
|
|
class="" |
|
|
|
style=" |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
font-size: 26rpx; |
|
|
|
font-weight: bold; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
margin-top: 20rpx; |
|
|
|
" |
|
|
|
> |
|
|
|
<view class="" style="width: 200rpx"> |
|
|
|
时长:{{ |
|
|
|
userInfo && userInfo.token ? userInfo.hour || 0 : 0 |
|
|
|
}}h |
|
|
|
</view> |
|
|
|
<view class=""> |
|
|
|
<image style="width: 22rpx;height: 22rpx;margin-right: 15rpx;" |
|
|
|
:src="showImg('/uploads/20250822/c8ee7615823a1ffaba400a4d5746de9a.png')"> |
|
|
|
<image |
|
|
|
style="width: 22rpx; height: 22rpx; margin-right: 15rpx" |
|
|
|
:src=" |
|
|
|
showImg( |
|
|
|
'/uploads/20250822/c8ee7615823a1ffaba400a4d5746de9a.png' |
|
|
|
) |
|
|
|
" |
|
|
|
> |
|
|
|
</image> |
|
|
|
点赞:0 |
|
|
|
点赞:{{ (userInfo && userInfo.likeCount) || 0 }} |
|
|
|
</view> |
|
|
|
<view class=""> |
|
|
|
<image style="width: 22rpx;height: 22rpx;margin: 0 15rpx;" |
|
|
|
:src="showImg('/uploads/20250822/84c49f78f1c86b7340aaaa391bd4b7cf.png')"> |
|
|
|
<image |
|
|
|
style="width: 22rpx; height: 22rpx; margin: 0 15rpx" |
|
|
|
:src=" |
|
|
|
showImg( |
|
|
|
'/uploads/20250822/84c49f78f1c86b7340aaaa391bd4b7cf.png' |
|
|
|
) |
|
|
|
" |
|
|
|
> |
|
|
|
</image> |
|
|
|
留言:0 |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<image class="avatar" @click="toWebView" |
|
|
|
<image |
|
|
|
class="avatar" |
|
|
|
@click="toWebView" |
|
|
|
src="https://epic.js-dyyj.com/uploads/20250826/92b0a21e9125fc21ca294a408bf3508f.png" |
|
|
|
mode="aspectFill"></image> |
|
|
|
mode="aspectFill" |
|
|
|
></image> |
|
|
|
</view> |
|
|
|
</template> |
|
|
|
</template> |
|
|
@ -141,9 +226,11 @@ |
|
|
|
<!-- 紧凑状态 --> |
|
|
|
<view v-else class="compact-content"> |
|
|
|
<text class="compact-name">{{ getCompactName() }}</text> |
|
|
|
<image class="compact-avatar" |
|
|
|
<image |
|
|
|
class="compact-avatar" |
|
|
|
src="https://epic.js-dyyj.com/uploads/20250826/92b0a21e9125fc21ca294a408bf3508f.png" |
|
|
|
mode="aspectFill"></image> |
|
|
|
mode="aspectFill" |
|
|
|
></image> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
@ -196,7 +283,7 @@ |
|
|
|
currentAvatar: "https://picsum.photos/80/80", |
|
|
|
currentAction: "激活你的Agent", |
|
|
|
userInfo: {}, |
|
|
|
totalPoints: 0 |
|
|
|
totalPoints: 0, |
|
|
|
}; |
|
|
|
}, |
|
|
|
computed: { |
|
|
@ -307,13 +394,13 @@ |
|
|
|
}, |
|
|
|
toOrder() { |
|
|
|
uni.switchTab({ |
|
|
|
url: '/pages/index/iSoul' |
|
|
|
}) |
|
|
|
url: "/pages/index/iSoul", |
|
|
|
}); |
|
|
|
}, |
|
|
|
toTime() { |
|
|
|
uni.switchTab({ |
|
|
|
url: '/pages/index/timeShopBank' |
|
|
|
}) |
|
|
|
url: "/pages/index/timeShopBank", |
|
|
|
}); |
|
|
|
}, |
|
|
|
getCompactName() { |
|
|
|
// 从用户信息中获取昵称 |
|
|
@ -324,8 +411,8 @@ |
|
|
|
}, |
|
|
|
toPoint() { |
|
|
|
uni.navigateTo({ |
|
|
|
url: '/subPackages/points/index' |
|
|
|
}) |
|
|
|
url: "/subPackages/points/index", |
|
|
|
}); |
|
|
|
}, |
|
|
|
getStatNumber(type) { |
|
|
|
// 从副标题中解析统计数据 |
|
|
@ -356,18 +443,20 @@ |
|
|
|
this.userInfo = |
|
|
|
(uni.getStorageSync("userInfo") && |
|
|
|
JSON.parse(uni.getStorageSync("userInfo"))) || |
|
|
|
this.$store.state.user.userInfo || {}; |
|
|
|
this.$store.state.user.userInfo || |
|
|
|
{}; |
|
|
|
console.log(this.userInfo, "this.userInfo"); |
|
|
|
// 更新标题显示用户昵称 |
|
|
|
if (this.userInfo && this.userInfo.nickname) { |
|
|
|
this.currentTitle = `Hi!${this.userInfo.nickname},欢迎回来~`; |
|
|
|
this.Post({}, '/framework/points/getLastBalance', 'DES').then(res => { |
|
|
|
this.Post({}, "/framework/points/getLastBalance", "DES").then( |
|
|
|
(res) => { |
|
|
|
if (res.code === 200) { |
|
|
|
this.totalPoints = res.data.balance || 0; |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
); |
|
|
|
} |
|
|
|
} catch (e) { |
|
|
|
console.warn("获取用户信息失败:", e); |
|
|
|
this.userInfo = {}; |
|
|
@ -379,21 +468,20 @@ |
|
|
|
// "https://des.dayunyuanjian.cn/dist/#/", |
|
|
|
// }); |
|
|
|
uni.navigateTo({ |
|
|
|
url: '/subPackages/other/evita?id=0' |
|
|
|
}) |
|
|
|
url: "/subPackages/other/evita?id=0", |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
toDesInfo() { |
|
|
|
uni.navigateTo({ |
|
|
|
url: '/subPackages/other/introduction' |
|
|
|
}) |
|
|
|
url: "/subPackages/other/introduction", |
|
|
|
}); |
|
|
|
}, |
|
|
|
pointDetail() { |
|
|
|
uni.navigateTo({ |
|
|
|
url:'/subPackages/user/privacyInfo?id=10222' |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
url: "/subPackages/user/privacyInfo?id=10222", |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
|
</script> |
|
|
|