123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246 |
- <template>
- <view class="page-view" style="width: 100vw;height: 100vh;">
- <top-return text="个人信息" color="#FFF"></top-return>
- <view class="detail-image"
- :style="{backgroundImage:`linear-gradient(to top, #f3f4f9, rgba(255, 255, 255, 0) 60%),url(${image})`}">
- </view>
- <!-- 个人头部信息 -->
- <view class="top-info">
- <image class="top-avatar" :src="parentInfo.avatarUrl"></image>
- <view class="top-name">
- <text class="name">{{parentInfo.nickName}}</text>
- <view class="tag-fill">
- <view class="t-icon t-icon-lianmengzhuanjia"></view>
- <view class="tag-text" style="color: #4169E1;font-size: 28rpx;">{{phoneNumber}} 绑定手机</view>
- </view>
- </view>
- </view>
- <!-- 卡片信息 -->
- <view class="main-card">
- <view class="flex-row">
- <view class="t-icon t-icon-huangguan"></view>
- <view class="flex-column">
- <view class="subtitle">我的订阅</view>
- <view class="title">{{userData.subscribeLevel}}</view>
- </view>
- </view>
- <view class="flex-row" style="margin-top: 50rpx;">
- <view class="t-icon t-icon-jiesuo"></view>
- <view class="flex-column">
- <view class="subtitle">订阅时间</view>
- <view class="title">{{userData.subscribeTime}}</view>
- </view>
- </view>
- <view class="flex-row" style="margin-top: 50rpx;">
- <view class="t-icon t-icon-quanxian"></view>
- <view class="flex-column">
- <view class="subtitle">订阅权益</view>
- <view class="title">{{userData.subscribePrivilege}}</view>
- </view>
- </view>
- <view class="card-view" style="margin-top: 40rpx;">
- <view class="flex-column-box" style="margin:0 auto 0 -40rpx;">
- <view class="column-title">孩子名片</view>
- <view class="bottom-tag"></view>
- </view>
- </view>
- <view class="card-box">
- <view class="card" v-for="(item,index) in childrenData" :key="index" @click="navChildInfo(index)">
- <image class="avatar" :src="item.gender==='M'?'/static/default_icons/boy_avatar.svg':item.gender===null?'/static/default_icons/boy_avatar.svg':'/static/default_icons/girl_avatar.svg'"></image>
- <view class="card-info">
- <view class="flex-baseline">
- <view class="YS-title">{{item.name}}</view>
- <view class="card-title">{{item.periodName}}学段</view>
- </view>
- <view class="flex-row">
- <view class="t-icon t-icon-xuewei1"></view>
- <view class="card-subtitle">{{item.schoolName}}</view>
- <view class="t-icon t-icon-zhengceguizhang2" style="margin-left: 20rpx;"></view>
- <view class="card-subtitle">{{item.className}}</view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- mapState
- } from 'vuex'
- export default {
- computed: {
- ...mapState('m_parent', ['parentInfo', 'phoneNumber', 'userData', 'childrenData']),
- },
- data() {
- return {
- image: 'https://image.meiye.art/pic_1628493294944',
- };
- },
- methods: {
- //孩子名片
- navChildInfo(index) {
- uni.navigateTo({
- url: `/subpkg/mine/childInfo?index=${index}`
- })
- },
- },
- }
- </script>
- <style lang="scss">
- .flex-column {
- display: flex;
- flex-direction: column;
- height: 80rpx;
- justify-content: space-between;
- }
- .detail-image {
- position: fixed;
- width: 100%;
- height: 800rpx;
- }
- .top-info {
- display: flex;
- align-items: center;
- margin-top: 180rpx;
- .top-avatar {
- margin-left: 50rpx;
- width: 140rpx;
- height: 140rpx;
- border-radius: 100%;
- border: 6rpx solid #FFF;
- box-shadow: 0 10rpx 20rpx rgba(0, 0, 0, 0.2);
- z-index: 55;
- }
- .top-name {
- margin-left: 50rpx;
- height: 130rpx;
- display: flex;
- flex-direction: column;
- justify-content: space-around;
- font-weight: bold;
- .name {
- color: $title;
- font-size: 45rpx;
- font-weight: bold;
- z-index: 55;
- }
- .t-icon {
- width: 32rpx;
- height: 32rpx;
- margin-right: 5rpx;
- }
- }
- }
- .main-card {
- display: flex;
- flex-direction: column;
- padding: 80rpx 80rpx 0 80rpx;
- position: relative;
- background-color: #FFF;
- height: 100%;
- top: 80rpx;
- left: 50rpx;
- border-radius: 50rpx;
- border-bottom-left-radius: 0;
- z-index: 55;
- .title {
- line-height: 32rpx;
- font-size: 32rpx;
- font-weight: 400;
- color: $title;
- }
- .subtitle {
- line-height: 28rpx;
- font-size: 28rpx;
- color: $subtitle;
- font-weight: 400;
- }
- .t-icon {
- margin-right: 30rpx;
- width: 80rpx;
- height: 80rpx;
- }
- }
- .flex-column-box {
- display: flex;
- flex-direction: column;
- .column-title {
- line-height: 35rpx;
- font-size: 32rpx;
- font-weight: bold;
- color: $title;
- }
- }
- .card-box {
- display: flex;
- align-items: center;
- flex-wrap: wrap; //元素换行
- .card {
- width: 100%;
- margin: 10rpx 0 10rpx 0;
- padding: 20rpx;
- display: flex;
- align-items: center;
- border: 2rpx solid #f3f4f9;
- background-color: #FFFFFF;
- border-radius: $border-radius;
- z-index: 99;
- .card-title {
- margin-left: 20rpx;
- font-size: 28rpx;
- color: $title;
- }
- .card-subtitle {
- line-height: 26rpx;
- font-size: 26rpx;
- color: $subtitle;
- }
- .avatar {
- width: 100rpx;
- height: 100rpx;
- }
- }
- }
- .tag-fill {
- background-color: #d8deff;
- width: fit-content;
- z-index: 99;
- }
- .card-info {
- display: flex;
- flex-direction: column;
- margin-left: 30rpx;
- height: 100rpx;
- justify-content: space-around;
- .t-icon {
- width: 32rpx;
- height: 32rpx;
- margin-right: 5rpx;
- }
- }
- </style>
|