@ -0,0 +1,36 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-03-26 10:06:38
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-03-26 10:14:12
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<button class="btn" :class="`btn__${type}`"><slot></slot></button>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
props : {
|
||||
type : String,
|
||||
default : 'line'
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.btn{
|
||||
display: inline-block;
|
||||
font-size: 28rpx;
|
||||
height: 64rpx;
|
||||
line-height: 64rpx;
|
||||
padding: 0 50rpx;
|
||||
text-align: center;
|
||||
border-radius: 50rpx;
|
||||
background: linear-gradient(270deg, #FF7F39 0%, #FFA35B 100%);
|
||||
color: #fff;
|
||||
&__line{
|
||||
background: none;
|
||||
color: #333;
|
||||
border: 1px solid rgb(192, 185, 185);
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,57 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-03-25 10:11:37
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-03-25 10:36:12
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<view class="header">
|
||||
<view class="header--title">
|
||||
<image class="header--back" v-if="back" src="@/static/search/arrow.png" @click="$Router.back()"></image>
|
||||
<slot name="title">{{title}}</slot>
|
||||
</view>
|
||||
<slot name="custom">
|
||||
<view class="header--operation">
|
||||
<slot name="operation"></slot>
|
||||
</view>
|
||||
</slot>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
props : {
|
||||
back : {
|
||||
type : Boolean,
|
||||
default : true
|
||||
},
|
||||
title : {
|
||||
type : String,
|
||||
default : ''
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.header{
|
||||
height: 88rpx;
|
||||
padding: 0 40rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background: #fff;
|
||||
position: sticky;
|
||||
top: var(--window-top);
|
||||
z-index: 999;
|
||||
&--back{
|
||||
width: 14rpx;
|
||||
height: 28rpx;
|
||||
margin-right: 20rpx;
|
||||
}
|
||||
&--title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
@ -1,653 +1,145 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2019-08-22 19:41:20
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-03-26 09:38:31
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<view v-if="!isFirstload" class="container">
|
||||
<!-- 页面头部 -->
|
||||
<view class="main-header"
|
||||
:style="{ height: $platform == 'H5' ? '240rpx' : '320rpx', paddingTop: $platform == 'H5' ? '0' : '50rpx' }">
|
||||
<image class="bg-image" src="/static/background/user-header.png" mode="scaleToFill"></image>
|
||||
<!-- 用户信息 -->
|
||||
<view v-if="isLogin" class="user-info">
|
||||
<view class="user-avatar">
|
||||
<!-- <avatar-image :url="userInfo.avatar_url" :width="100" /> -->
|
||||
</view>
|
||||
<view class="user-content">
|
||||
<!-- 会员昵称 -->
|
||||
<view class="nick-name oneline-hide">{{ userInfo.nick_name }}</view>
|
||||
<!-- 会员等级 -->
|
||||
<view v-if="userInfo.grade_id > 0 && userInfo.grade" class="user-grade">
|
||||
<view class="user-grade_icon">
|
||||
<image class="image"
|
||||
src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAA0lBMVEUAAAD/tjL/tzH/uDP/uC7/tjH/tzH/tzL/tTH+tTL+tjP/tDD/tTD+tzD/tjL/szD/uDH/tjL/tjL+tjD/tjT/szb/tzL/tTL+uTH+tjL/tjL/tjL/tTT/tjL/tjL+tjH/uTL/vDD/tjL/tjH/tzL9uS//tTL/nBr/sS7/tjH/ujL/szD/uTv+rzf/tzL+tzH+vDP+uzL+tjP+ry7+tDL9ki/7szf/sEX/tTL/tjL+tjL/tTH/tTT/tzH/tzL/tjP/sTX/uTP/wzX+rTn/vDX9vC8m8ckhAAAAOXRSTlMAlnAMB/vjxKWGMh0S6drMiVxPRkEY9PLy0ru0sKagmo5+dGtgVCMgBP716eXWyMGxqJGRe2o5KSmFNjaYAAABP0lEQVQ4y8XS13KDMBAF0AWDDe4t7r3ETu9lVxJgJ/n/X8rKAzHG5TE+Twz3zki7I/g/KXdghIbGJewrU4yzn08Ebgl6TuZzzuOC6W5es3HX6qsSz3NFShRU0MpucytDmOSpu3yULx3CA9RD1HjVedc0jSjqm6ZzhUjDsFDQhSp/OKj5GQvg0+ZCOixsbtDLAeTTOm/yGi8GyIphIVsgH737FEDV44LJa88IRKK/SetrwT9G/GUIr6vXjoy4GXn7+RboVXnghuSjaoGecwQxL2su3CwAKlO+QFoqxI4FMctHQhQd2OhxTu184jWUlI+rMTBTn1/IQcJHQ6GQdZ7pWiDaNdhTt330efISeiqYwQEzQpTlsURJLhzkEmpCPsERfeIUVyXr6MNuIyp5uziW6xURtt7hhGwzmMNJExfO4Bd9X0ZPqAxdNwAAAABJRU5ErkJggg==">
|
||||
</image>
|
||||
</view>
|
||||
<view class="user-grade_name">
|
||||
<text>{{ userInfo.grade.name }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 会员无等级时显示手机号 -->
|
||||
<view v-else class="mobile">{{ userInfo.mobile }}</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 未登录 -->
|
||||
<view v-else class="user-info" @click="handleLogin">
|
||||
<view class="user-avatar">
|
||||
<avatar-image :width="100" />
|
||||
</view>
|
||||
<view class="user-content">
|
||||
<view class="nick-name">未登录</view>
|
||||
<view class="login-tips">点击登录账号</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 我的钱包 -->
|
||||
<view class="my-asset">
|
||||
<view class="asset-left flex-box dis-flex flex-x-around">
|
||||
<view class="asset-left-item" @click="onTargetWallet">
|
||||
<view class="item-value dis-flex flex-x-center">
|
||||
<text>{{ isLogin ? assets.balance : '--' }}</text>
|
||||
</view>
|
||||
<view class="item-name dis-flex flex-x-center">
|
||||
<text>账户余额</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="asset-left-item" @click="onTargetPoints">
|
||||
<view class="item-value dis-flex flex-x-center">
|
||||
<text>{{ isLogin ? assets.points : '--' }}</text>
|
||||
</view>
|
||||
<view class="item-name dis-flex flex-x-center">
|
||||
<text>{{ setting[SettingKeyEnum.POINTS.value].points_name }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="asset-left-item" @click="onTargetMyCoupon">
|
||||
<view class="item-value dis-flex flex-x-center">
|
||||
<text>{{ isLogin ? assets.coupon : '--' }}</text>
|
||||
</view>
|
||||
<view class="item-name dis-flex flex-x-center">
|
||||
<text>优惠券</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="asset-right">
|
||||
<view class="asset-right-item" @click="onTargetWallet">
|
||||
<view class="item-icon dis-flex flex-x-center">
|
||||
<text class="iconfont icon-qianbao"></text>
|
||||
</view>
|
||||
<view class="item-name dis-flex flex-x-center">
|
||||
<text>我的钱包</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 订单操作 -->
|
||||
<view class="order-navbar">
|
||||
<view class="order-navbar-item" v-for="(item, index) in orderNavbar" :key="index" @click="onTargetOrder(item)">
|
||||
<view class="item-icon">
|
||||
<text class="iconfont" :class="[`icon-${item.icon}`]"></text>
|
||||
</view>
|
||||
<view class="item-name">{{ item.name }}</view>
|
||||
<view class="item-badge" v-if="item.count && item.count > 0">
|
||||
<text v-if="item.count <= 99" class="text">{{ item.count }}</text>
|
||||
<text v-else class="text">99+</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 我的服务 -->
|
||||
<view class="my-service">
|
||||
<view class="service-title">我的服务</view>
|
||||
<view class="service-content clearfix">
|
||||
<block v-for="(item, index) in service" :key="index">
|
||||
<view v-if="item.type == 'link'" class="service-item" @click="handleService(item)">
|
||||
<view class="item-icon">
|
||||
<text class="iconfont" :class="[`icon-${item.icon}`]"></text>
|
||||
</view>
|
||||
<view class="item-name">{{ item.name }}</view>
|
||||
<view class="item-badge" v-if="item.count && item.count > 0">
|
||||
<text v-if="item.count <= 99" class="text">{{ item.count }}</text>
|
||||
<text v-else class="text">99+</text>
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="item.type == 'button' && $platform == 'MP-WEIXIN'" class="service-item">
|
||||
<button class="btn-normal" :open-type="item.openType">
|
||||
<view class="item-icon">
|
||||
<text class="iconfont" :class="[`icon-${item.icon}`]"></text>
|
||||
</view>
|
||||
<view class="item-name">{{ item.name }}</view>
|
||||
</button>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 退出登录 -->
|
||||
<view v-if="isLogin" class="my-logout">
|
||||
<view class="logout-btn" @click="handleLogout()">
|
||||
<text>退出登录</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view>
|
||||
<view class="header">
|
||||
<u-badge class="header--badge" max="99" :value="9"></u-badge>
|
||||
<image class="header--msg" src="@/static/account/xx.png" />
|
||||
</view>
|
||||
<u-cell :isLink="true" arrow-direction="right" :clickable="false" title="昵称" label="第一个青春是上帝给的..." :border="false">
|
||||
<image slot="icon" class="head-img" src="@/static/account/tx.png" shape="circle" />
|
||||
</u-cell>
|
||||
<view class="order">
|
||||
<view class="order--title">
|
||||
<text>我的订单</text>
|
||||
<text class="order--title-more">查看更多</text>
|
||||
</view>
|
||||
<view class="order-tabs">
|
||||
<view class="order-tabs--item">
|
||||
<u-badge class="item-badge" max="99" :value="9"></u-badge>
|
||||
<image class="item-icon" src="@/static/account/fk.png"/>
|
||||
<view>待付款</view>
|
||||
</view>
|
||||
<view class="order-tabs--item">
|
||||
<u-badge class="item-badge" max="99" :value="9"></u-badge>
|
||||
<image class="item-icon" src="@/static/account/fh.png"/>
|
||||
<view>待发货</view>
|
||||
</view>
|
||||
<view class="order-tabs--item">
|
||||
<u-badge class="item-badge" max="99" :value="9"></u-badge>
|
||||
<image class="item-icon" src="@/static/account/sh.png"/>
|
||||
<view>待收货</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="cell">
|
||||
<u-cell class="cell--item" :isLink="true" arrow-direction="right" title="退货/售后">
|
||||
<image slot="icon" class="cell--icon" src="@/static/account/tk.png" shape="circle" />
|
||||
</u-cell>
|
||||
<u-cell class="cell--item" :isLink="true" arrow-direction="right" title="收货地址">
|
||||
<image slot="icon" class="cell--icon" src="@/static/common/dz.png" shape="circle" />
|
||||
</u-cell>
|
||||
<u-cell class="cell--item" :isLink="true" arrow-direction="right" title="联系客服">
|
||||
<image slot="icon" class="cell--icon" src="@/static/account/kf.png" shape="circle" />
|
||||
</u-cell>
|
||||
<u-cell class="cell--item" :isLink="true" arrow-direction="right" title="设置">
|
||||
<image slot="icon" class="cell--icon" src="@/static/account/sz.png" shape="circle" />
|
||||
</u-cell>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import store from '@/store'
|
||||
// import AvatarImage from '@/components/avatar-image'
|
||||
// import { setCartTabBadge } from '@/core/app'
|
||||
import SettingKeyEnum from '@/common/enum/setting/Key'
|
||||
// import SettingModel from '@/common/model/Setting'
|
||||
// import * as UserApi from '@/api/user'
|
||||
// import * as OrderApi from '@/api/order'
|
||||
// import { checkLogin } from '@/core/app'
|
||||
import userInfoData from '@/mock/userInfo.json';
|
||||
import addressData from '@/mock/address.json';
|
||||
import countData from '@/mock/todoCounts.json';
|
||||
import sessingData from '@/mock/setting.json';
|
||||
|
||||
// 订单操作
|
||||
const orderNavbar = [
|
||||
{ id: 'all', name: '全部订单', icon: 'qpdingdan' },
|
||||
{ id: 'payment', name: '待支付', icon: 'daifukuan', count: 0 },
|
||||
{ id: 'delivery', name: '待发货', icon: 'daifahuo', count: 0 },
|
||||
{ id: 'received', name: '待收货', icon: 'daishouhuo', count: 0 },
|
||||
]
|
||||
|
||||
/**
|
||||
* 我的服务
|
||||
* id: 标识; name: 标题名称; icon: 图标; type 类型(link和button); url: 跳转的链接
|
||||
*/
|
||||
const service = [
|
||||
{ id: 'address', name: '收货地址', icon: 'shouhuodizhi', type: 'link', url: 'pages/address/index' },
|
||||
{ id: 'coupon', name: '领券中心', icon: 'lingquan', type: 'link', url: 'pages/coupon/index' },
|
||||
{ id: 'myCoupon', name: '优惠券', icon: 'youhuiquan', type: 'link', url: 'pages/my-coupon/index' },
|
||||
{ id: 'help', name: '我的帮助', icon: 'bangzhu', type: 'link', url: 'pages/help/index' },
|
||||
{ id: 'contact', name: '在线客服', icon: 'kefu', type: 'button', openType: 'contact' },
|
||||
{ id: 'points', name: '我的积分', icon: 'jifen', type: 'link', url: 'pages/points/log' },
|
||||
{ id: 'refund', name: '退换/售后', icon: 'shouhou', type: 'link', url: 'pages/refund/index', count: 0 },
|
||||
]
|
||||
|
||||
export default {
|
||||
components: {
|
||||
// AvatarImage
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
// 枚举类
|
||||
SettingKeyEnum,
|
||||
// 当前运行的终端 (此处并不冗余,因为微信小程序端view层无法直接读取$platform)
|
||||
$platform: this.$platform,
|
||||
// 正在加载
|
||||
isLoading: true,
|
||||
// 首次加载
|
||||
isFirstload: true,
|
||||
// 是否已登录
|
||||
isLogin: false,
|
||||
// 系统设置
|
||||
setting: {},
|
||||
// 当前用户信息
|
||||
userInfo: {},
|
||||
// 账户资产
|
||||
assets: { balance: '--', points: '--', coupon: '--' },
|
||||
// 我的服务
|
||||
service,
|
||||
// 订单操作
|
||||
orderNavbar,
|
||||
// 当前用户待处理的订单数量
|
||||
todoCounts: { payment: 0, deliver: 0, received: 0 }
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow(options) {
|
||||
this.onRefreshPage()
|
||||
},
|
||||
|
||||
methods: {
|
||||
|
||||
// 刷新页面
|
||||
onRefreshPage() {
|
||||
// 更新购物车角标
|
||||
// setCartTabBadge()
|
||||
// 判断是否已登录
|
||||
this.isLogin = true //checkLogin()
|
||||
// 获取页面数据
|
||||
this.getPageData()
|
||||
},
|
||||
|
||||
// 获取页面数据
|
||||
getPageData(callback) {
|
||||
const app = this
|
||||
app.isLoading = true;
|
||||
app.getSetting();
|
||||
app.getUserInfo();
|
||||
app.getUserAssets();
|
||||
app.getTodoCounts();
|
||||
|
||||
app.isFirstload = false
|
||||
// Promise.all([app.getSetting(), app.getUserInfo(), app.getUserAssets(), app.getTodoCounts()])
|
||||
// .then(result => {
|
||||
// console.log('----')
|
||||
// app.isFirstload = false
|
||||
// // 初始化我的服务数据
|
||||
app.initService()
|
||||
// // 初始化订单操作数据
|
||||
app.initOrderTabbar()
|
||||
// // 执行回调函数
|
||||
callback && callback()
|
||||
// })
|
||||
// .catch(err => console.log('catch', err))
|
||||
// .finally(() => app.isLoading = false)
|
||||
},
|
||||
|
||||
// 初始化我的服务数据
|
||||
initService() {
|
||||
const app = this
|
||||
const newService = []
|
||||
service.forEach(item => {
|
||||
if (item.id === 'points') {
|
||||
item.name = '我的' + app.setting[SettingKeyEnum.POINTS.value].points_name
|
||||
}
|
||||
// 数据角标
|
||||
if (item.count != undefined) {
|
||||
item.count = app.todoCounts[item.id]
|
||||
}
|
||||
newService.push(item)
|
||||
})
|
||||
app.service = newService
|
||||
},
|
||||
|
||||
// 初始化订单操作数据
|
||||
initOrderTabbar() {
|
||||
const app = this
|
||||
const newOrderNavbar = []
|
||||
orderNavbar.forEach(item => {
|
||||
if (item.count != undefined) {
|
||||
item.count = app.todoCounts[item.id]
|
||||
}
|
||||
newOrderNavbar.push(item)
|
||||
})
|
||||
app.orderNavbar = newOrderNavbar
|
||||
},
|
||||
|
||||
// 获取商城设置
|
||||
getSetting() {
|
||||
const app = this
|
||||
app.setting = sessingData.data.setting
|
||||
// return new Promise((resolve, reject) => {
|
||||
// SettingModel.data()
|
||||
// .then(setting => {
|
||||
// app.setting = setting
|
||||
// resolve(setting)
|
||||
// }).catch(reject)
|
||||
// })
|
||||
},
|
||||
|
||||
// 获取当前用户信息
|
||||
getUserInfo() {
|
||||
const app = this
|
||||
app.userInfo = userInfoData.data.userInfo;
|
||||
// return new Promise((resolve, reject) => {
|
||||
// !app.isLogin ? resolve(null) :
|
||||
// UserApi.info({}, { load: app.isFirstload })
|
||||
// .then(result => {
|
||||
// app.userInfo = result.data.userInfo
|
||||
// resolve(app.userInfo)
|
||||
// })
|
||||
// .catch(err => {
|
||||
// if (err.result && err.result.status == 401) {
|
||||
// app.isLogin = false
|
||||
// resolve(null)
|
||||
// } else {
|
||||
// reject(err)
|
||||
// }
|
||||
// })
|
||||
// })
|
||||
},
|
||||
|
||||
// 获取账户资产
|
||||
getUserAssets() {
|
||||
const app = this
|
||||
app.assets = addressData.data.assets;
|
||||
// return new Promise((resolve, reject) => {
|
||||
// !app.isLogin ? resolve(null) :
|
||||
// UserApi.assets({}, { load: app.isFirstload })
|
||||
// .then(result => {
|
||||
// app.assets = result.data.assets
|
||||
// resolve(app.assets)
|
||||
// })
|
||||
// .catch(err => {
|
||||
// if (err.result && err.result.status == 401) {
|
||||
// app.isLogin = false
|
||||
// resolve(null)
|
||||
// } else {
|
||||
// reject(err)
|
||||
// }
|
||||
// })
|
||||
// })
|
||||
},
|
||||
|
||||
// 获取当前用户待处理的订单数量
|
||||
getTodoCounts() {
|
||||
const app = this
|
||||
app.todoCounts = countData.data.counts
|
||||
// return new Promise((resolve, reject) => {
|
||||
// !app.isLogin ? resolve(null) :
|
||||
// OrderApi.todoCounts({}, { load: app.isFirstload })
|
||||
// .then(result => {
|
||||
// app.todoCounts = result.data.counts
|
||||
// resolve(app.todoCounts)
|
||||
// })
|
||||
// .catch(err => {
|
||||
// if (err.result && err.result.status == 401) {
|
||||
// app.isLogin = false
|
||||
// resolve(null)
|
||||
// } else {
|
||||
// reject(err)
|
||||
// }
|
||||
// })
|
||||
// })
|
||||
},
|
||||
|
||||
// 跳转到登录页
|
||||
handleLogin() {
|
||||
!this.isLogin && this.$navTo('pages/login/index')
|
||||
},
|
||||
|
||||
// 退出登录
|
||||
handleLogout() {
|
||||
const app = this
|
||||
uni.showModal({
|
||||
title: '友情提示',
|
||||
content: '您确定要退出登录吗?',
|
||||
success(res) {
|
||||
if (res.confirm) {
|
||||
// store.dispatch('Logout', {})
|
||||
// .then(result => app.onRefreshPage())
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 跳转到钱包页面
|
||||
onTargetWallet() {
|
||||
this.$navTo('pages/wallet/index')
|
||||
},
|
||||
|
||||
// 跳转到订单页
|
||||
onTargetOrder(item) {
|
||||
this.$navTo('pages/order/index', { dataType: item.id })
|
||||
},
|
||||
|
||||
// 跳转到我的积分页面
|
||||
onTargetPoints() {
|
||||
this.$navTo('pages/points/log')
|
||||
},
|
||||
|
||||
// 跳转到我的优惠券页
|
||||
onTargetMyCoupon() {
|
||||
this.$navTo('pages/my-coupon/index')
|
||||
},
|
||||
|
||||
// 跳转到服务页面
|
||||
handleService({ url }) {
|
||||
this.$navTo(url)
|
||||
},
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 下拉刷新
|
||||
*/
|
||||
onPullDownRefresh() {
|
||||
// 获取首页数据
|
||||
this.getPageData(() => {
|
||||
uni.stopPullDownRefresh()
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
// 页面头部
|
||||
.main-header {
|
||||
background-color: #fff;
|
||||
// background-image: url('/static/background/user-header.png');
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 280rpx;
|
||||
background-size: 100% 100%;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
// padding-top: 40rpx;
|
||||
padding-left: 30rpx;
|
||||
|
||||
.bg-image {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 0;
|
||||
}
|
||||
|
||||
.user-info {
|
||||
display: flex;
|
||||
height: 100rpx;
|
||||
z-index: 1;
|
||||
|
||||
.user-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
margin-left: 30rpx;
|
||||
color: #c59a46;
|
||||
|
||||
.nick-name {
|
||||
font-size: 32rpx;
|
||||
font-weight: bold;
|
||||
max-width: 270rpx;
|
||||
}
|
||||
|
||||
.mobile {
|
||||
margin-top: 15rpx;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
|
||||
.user-grade {
|
||||
align-self: baseline;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
background: #3c3c3c;
|
||||
margin-top: 12rpx;
|
||||
border-radius: 10rpx;
|
||||
padding: 4rpx 12rpx;
|
||||
|
||||
.user-grade_icon .image {
|
||||
display: block;
|
||||
width: 32rpx;
|
||||
height: 32rpx;
|
||||
}
|
||||
|
||||
.user-grade_name {
|
||||
margin-left: 5rpx;
|
||||
font-size: 24rpx;
|
||||
color: #EEE0C3;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.login-tips {
|
||||
margin-top: 12rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 角标组件
|
||||
.item-badge {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 55rpx;
|
||||
background: #fa2209;
|
||||
color: #fff;
|
||||
border-radius: 100%;
|
||||
min-width: 38rpx;
|
||||
height: 38rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 1rpx;
|
||||
font-size: 22rpx;
|
||||
}
|
||||
|
||||
// 我的钱包
|
||||
.my-asset {
|
||||
display: flex;
|
||||
background: #fff;
|
||||
padding: 40rpx 0;
|
||||
|
||||
.asset-right {
|
||||
width: 200rpx;
|
||||
border-left: 1rpx solid #eee;
|
||||
}
|
||||
|
||||
.asset-right-item {
|
||||
text-align: center;
|
||||
color: #545454;
|
||||
|
||||
.item-icon {
|
||||
font-size: 40rpx;
|
||||
}
|
||||
|
||||
.item-name {
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
|
||||
.item-name text {
|
||||
font-size: 25rpx;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.asset-left-item {
|
||||
text-align: center;
|
||||
color: #666;
|
||||
padding: 0 42rpx;
|
||||
|
||||
.item-value {
|
||||
font-size: 32rpx;
|
||||
color: red;
|
||||
}
|
||||
|
||||
.item-name {
|
||||
margin-top: 6rpx;
|
||||
}
|
||||
|
||||
.item-name {
|
||||
font-size: 25rpx;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// 订单操作
|
||||
.order-navbar {
|
||||
display: flex;
|
||||
margin: 20rpx auto 20rpx auto;
|
||||
padding: 20rpx 0;
|
||||
width: 94%;
|
||||
box-shadow: 0 1rpx 5rpx 0px rgba(0, 0, 0, 0.05);
|
||||
font-size: 30rpx;
|
||||
border-radius: 5rpx;
|
||||
background: #fff;
|
||||
|
||||
&-item {
|
||||
position: relative;
|
||||
width: 25%;
|
||||
|
||||
.item-icon {
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
padding: 10rpx 0;
|
||||
color: #545454;
|
||||
font-size: 40rpx;
|
||||
}
|
||||
|
||||
.item-name {
|
||||
font-size: 26rpx;
|
||||
color: #545454;
|
||||
text-align: center;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// 我的服务
|
||||
.my-service {
|
||||
margin: 22rpx auto 22rpx auto;
|
||||
padding: 20rpx 0;
|
||||
width: 94%;
|
||||
box-shadow: 0 1rpx 5rpx 0px rgba(0, 0, 0, 0.05);
|
||||
border-radius: 5rpx;
|
||||
background: #fff;
|
||||
|
||||
.service-title {
|
||||
padding-left: 20rpx;
|
||||
margin-bottom: 30rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
.service-content {
|
||||
|
||||
// margin-bottom: -30rpx;
|
||||
.service-item {
|
||||
position: relative;
|
||||
width: 25%;
|
||||
float: left;
|
||||
margin-bottom: 30rpx;
|
||||
|
||||
.item-icon {
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
padding: 10rpx 0;
|
||||
color: #ff3800;
|
||||
font-size: 40rpx;
|
||||
}
|
||||
|
||||
.item-name {
|
||||
font-size: 26rpx;
|
||||
color: #545454;
|
||||
text-align: center;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 退出登录
|
||||
.my-logout {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: 50rpx;
|
||||
|
||||
.logout-btn {
|
||||
width: 50%;
|
||||
margin: 0 auto;
|
||||
font-size: 26rpx;
|
||||
color: #616161;
|
||||
border-radius: 20rpx;
|
||||
border: 1px solid #dcdcdc;
|
||||
padding: 14rpx 0;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
page{
|
||||
background: url('@/static/account/bg.png') no-repeat top left #F8F8F8;
|
||||
background-size: 100%;
|
||||
}
|
||||
.header{
|
||||
height: 88rpx;
|
||||
display: flex;
|
||||
justify-content: end;
|
||||
align-items: center;
|
||||
padding: 0 40rpx;
|
||||
position: relative;
|
||||
&--msg{
|
||||
width: 34rpx;
|
||||
height: 40rpx
|
||||
}
|
||||
&--badge{
|
||||
position: absolute;
|
||||
right: 30rpx;
|
||||
top: 10rpx;
|
||||
z-index: 99;
|
||||
}
|
||||
}
|
||||
.head-img{
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
border-radius: 50%;
|
||||
margin-right: 30rpx;
|
||||
}
|
||||
.order{
|
||||
width: 630rpx;
|
||||
height: 200rpx;
|
||||
background: #fff;
|
||||
border-radius: 16rpx;
|
||||
margin: 40rpx auto;
|
||||
padding: 30rpx;
|
||||
box-shadow: 0 0 13rpx 1px rgba(0, 0, 0, .05);
|
||||
&--title{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background: url('@/static/common/arrow.png') no-repeat center right;
|
||||
background-size: 10rpx;
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
margin: 10rpx 0 46rpx;
|
||||
}
|
||||
&--title-more{
|
||||
padding-right: 20rpx;
|
||||
font-size: 24rpx;
|
||||
color: #999;
|
||||
}
|
||||
&-tabs{
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
&--item{
|
||||
text-align: center;
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
position: relative;
|
||||
.item-icon{
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
}
|
||||
.item-badge{
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 0;
|
||||
z-index: 99;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.cell{
|
||||
margin: 30rpx;
|
||||
border-radius: 16rpx;
|
||||
background: #fff;
|
||||
padding: 0 40rpx;
|
||||
&--icon{
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -0,0 +1,60 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-03-26 14:32:03
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-03-26 15:03:18
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<view>
|
||||
<view class="msgItem" v-for="item in 5" :key="item">
|
||||
<view class="msgItem--title">
|
||||
<text>退款消息</text>
|
||||
<text class="msgItem--time">03-23 00:00</text>
|
||||
</view>
|
||||
<view class="msgItem--con">
|
||||
<image class="msgItem--img" src="@/static/testImg/3.png" mode="widthFix"/>
|
||||
<view class="msgItem--desc">马士兵新款多线程与高并发专项训练突破课程书籍项训练突破课程书籍项训练突破</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.msgItem{
|
||||
padding: 40rpx 0 0 40rpx;
|
||||
&--title{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding-right: 40rpx;
|
||||
font-size: 32rpx;
|
||||
color: #333;
|
||||
}
|
||||
&--time{
|
||||
font-size: 24rpx;
|
||||
color: #999;
|
||||
}
|
||||
&--con{
|
||||
display: flex;
|
||||
border-bottom: 1px solid #eee;
|
||||
padding: 40rpx 0;
|
||||
}
|
||||
&--img{
|
||||
width: 140rpx;
|
||||
height: 140rpx;
|
||||
border-radius: 12rpx;
|
||||
margin-right: 40rpx;
|
||||
}
|
||||
&--desc{
|
||||
width: 455rpx;
|
||||
font-size: 28rpx;
|
||||
line-height: 39rpx;
|
||||
color: #666;
|
||||
}
|
||||
}
|
||||
</style>
|
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 906 B |
After Width: | Height: | Size: 915 B |
After Width: | Height: | Size: 827 B |
After Width: | Height: | Size: 976 B |
After Width: | Height: | Size: 884 B |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 6.5 KiB |
After Width: | Height: | Size: 536 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 20 KiB |
After Width: | Height: | Size: 15 KiB |
After Width: | Height: | Size: 728 B |
After Width: | Height: | Size: 782 B |
After Width: | Height: | Size: 760 B |
After Width: | Height: | Size: 284 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 410 B |
After Width: | Height: | Size: 435 B |