123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- <!-- vip权益 -->
- <template>
- <view class="box">
- <!-- vip信息 -->
- <view class="vipBox">
- <view class="avatar">
- <img :src="getUserAvatar(baseInfo?.avatar, baseInfo?.sex)" alt="" class="img-box">
- <image src="/static/svg/vip.svg" class="vipIcon"></image>
- </view>
- <view class="nameBox">
- <view class="name font-weight-bold font-size-16">{{ baseInfo?.name || userInfo?.phone }}</view>
- </view>
- </view>
- <view style="height: 20rpx; background-color: #f8f8fa;"></view>
- <view class="card">
- <uni-list>
- <uni-list-item
- v-for="item in list"
- :clickable="true"
- :key="item.title"
- :title="item.title"
- showArrow
- :rightText="item.rightTex || ''"
- @click="handleToLink(item)"
- >
- </uni-list-item>
- </uni-list>
- </view>
- </view>
- </template>
- <script setup>
- import { userStore } from '@/store/user'
- import { ref, computed, watch } from 'vue'
- import { getUserAvatar } from '@/utils/avatar'
- const useUserStore = userStore()
- const baseInfo = computed(() => useUserStore?.baseInfo)
- const userInfo = computed(() => useUserStore?.userInfo)
- const list = ref([
- { title: '简历模板', path: '/pagesA/vip/template/index' },
- { title: '屏蔽企业', path: '/pagesA/vip/blockEnt/index' },
- ])
- // 列表跳转
- const handleToLink = (item) => {
- uni.navigateTo({
- url: item.path
- })
- }
- </script>
- <style lang="scss" scoped>
- .vipBox {
- // color: #a18a0f;
- padding: 80rpx 50rpx;
- display: flex;
- background: linear-gradient(121deg,#fde2c2 29.02%,#c19164 104.03%);
- .avatar{
- position: relative;
- width: 100rpx;
- height: 100rpx;
- margin: 0;
- .img-box {
- width: 100%;
- height: 100%;
- border: 2rpx solid #ccc;
- border-radius: 50%;
- border: 1px solid gold;
- }
- .vipIcon {
- position: absolute;
- width: 50%;
- height: 50%;
- bottom: 0;
- right: 0;
- transform: translate(0, 30%);
- }
- }
- .nameBox {
- margin-left: 30rpx;
- .name {
- color: #724d2b;
- }
- }
- }
- :deep(.uni-list-item) {
- height: 120rpx !important;
- line-height: 120rpx !important;
- }
- :deep(.uni-list-item__content-title) {
- font-size: 32rpx !important;
- font-weight: 500;
- }
- </style>
|