|
|
@@ -4,23 +4,26 @@
|
|
|
<view class="content-info">
|
|
|
<!-- 轮播图 -->
|
|
|
<view class="head-bg">
|
|
|
- <img src="/static/me/u655.png" style="height: 520rpx;width: 750rpx;" alt="">
|
|
|
+ <u-swiper :list="bannerList" :height="340"></u-swiper>
|
|
|
</view>
|
|
|
<view class="content">
|
|
|
<!-- 用户信息 -->
|
|
|
<view @click="perfectUserInfo()" class="user-info">
|
|
|
<view class="user-head">
|
|
|
- <image class="user-image" v-if="userInfo.selfPhotoUrl" :src="userInfo.selfPhotoUrl" mode="">
|
|
|
- </image>
|
|
|
- <image class="user-image" v-else src="../../static/logo.png" mode=""></image>
|
|
|
+ <image v-if="userInfo.selfPhotoUrl" :src="userInfo.selfPhotoUrl" mode=""></image>
|
|
|
+ <image v-else src="../../static/logo.png" mode=""></image>
|
|
|
</view>
|
|
|
- <view class="head-right">
|
|
|
+ <view class="h-content">
|
|
|
<view class="user-name">
|
|
|
- <strong>HI,亲爱的{{ userInfo.ncikName }}</strong>
|
|
|
+ <text>HI,亲爱的{{ userInfo.ncikName }}</text>
|
|
|
</view>
|
|
|
<view class="user-desc">
|
|
|
<view class="h-text">
|
|
|
- <view>你当前的个人资料尚不完善,去完善 <uni-icons type="right" size="15"></uni-icons></view>
|
|
|
+ <text>你当前的个人资料尚不完善</text>
|
|
|
+ <text>去完善</text>
|
|
|
+ </view>
|
|
|
+ <view class="h-arrow">
|
|
|
+ <u-icon name="arrow-right" color="#333333" size="16"></u-icon>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -41,22 +44,22 @@
|
|
|
余额
|
|
|
</view>
|
|
|
<view class="num">
|
|
|
- 999
|
|
|
+ ¥{{ userInfo.balance }}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="button-wrap">
|
|
|
- <view class="btn">
|
|
|
+ <view @click="gotoIntgral" class="btn">
|
|
|
<view class="icon">
|
|
|
<u-icon name="/static/me/u680.png" color="red" size="30"></u-icon>
|
|
|
</view>
|
|
|
<view class="h-name">
|
|
|
- <view class="name" style="font-size: 24rpx;">
|
|
|
+ <view class="name">
|
|
|
积分
|
|
|
</view>
|
|
|
<view class="num">
|
|
|
- 999
|
|
|
+ {{ userInfo.integral }}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -71,7 +74,7 @@
|
|
|
优惠券
|
|
|
</view>
|
|
|
<view class="num">
|
|
|
- 999
|
|
|
+ {{ userInfo.coupon }}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -86,7 +89,7 @@
|
|
|
电子币
|
|
|
</view>
|
|
|
<view class="num">
|
|
|
- 999
|
|
|
+ {{ userInfo.electronicCurrency }}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -94,11 +97,11 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
- <view class="nav-bar1">
|
|
|
+ <view class="nav-bar">
|
|
|
<view class="nav-content">
|
|
|
<view class="nav-info">
|
|
|
<view class="logo">
|
|
|
- <image src="../../static/me/u1796.png" style="transform: scale(.2);" mode=""></image>
|
|
|
+ <image src="../../static/me/u1796.png" mode=""></image>
|
|
|
</view>
|
|
|
<view class="nav-desc">
|
|
|
<view class="nav-name">
|
|
|
@@ -112,11 +115,11 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
+ <view class="custom-line"></view>
|
|
|
<view @click="gotoRealNameAuth()" class="nav-content">
|
|
|
<view class="nav-info">
|
|
|
<view class="logo">
|
|
|
- <image src="../../static/me/u1803.png" style="transform: scale(.2);" mode=""></image>
|
|
|
+ <image src="../../static/me/u1803.png" mode=""></image>
|
|
|
</view>
|
|
|
<view class="nav-desc">
|
|
|
<view class="nav-name">
|
|
|
@@ -133,24 +136,26 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
+ <view class="custom-line"></view>
|
|
|
<view @click="gotoServiceObjectMgt()" class="nav-content">
|
|
|
- <view class="logo">
|
|
|
- <image src="../../static/me/u1812.png" style="transform: scale(.2);" mode=""></image>
|
|
|
- </view>
|
|
|
- <view class="nav-desc">
|
|
|
- <view class="nav-name">
|
|
|
- <view class="">服务对象管理</view>
|
|
|
+ <view class="nav-info">
|
|
|
+ <view class="logo">
|
|
|
+ <image src="../../static/me/u1812.png" mode=""></image>
|
|
|
+ </view>
|
|
|
+ <view class="nav-desc">
|
|
|
+ <view class="nav-name">
|
|
|
+ <view class="">服务对象管理</view>
|
|
|
|
|
|
+ </view>
|
|
|
+ <view class="change-store"></view>
|
|
|
+ </view>
|
|
|
+ <view class="arrow-right">
|
|
|
+ <u-icon name="arrow-right" color="#666" size="18"></u-icon>
|
|
|
+ <!-- <image src="../../static/index/u10.png" mode=""></image> -->
|
|
|
</view>
|
|
|
- <view class="change-store"></view>
|
|
|
- </view>
|
|
|
- <view class="arrow-right">
|
|
|
- <u-icon name="arrow-right" color="#666" size="18"></u-icon>
|
|
|
- <!-- <image src="../../static/index/u10.png" mode=""></image> -->
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
+ <view class="custom-line"></view>
|
|
|
<view class="nav-content">
|
|
|
<view @click="gotoSystemSwitch()" class="nav-info">
|
|
|
<view class="logo">
|
|
|
@@ -189,7 +194,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
- <view class="nav-bar2">
|
|
|
+ <view class="nav-bar">
|
|
|
<view @click="aboutOur()" class="nav-content">
|
|
|
<view class="nav-info">
|
|
|
<view class="logo">
|
|
|
@@ -246,10 +251,9 @@
|
|
|
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
-
|
|
|
</view>
|
|
|
</view>
|
|
|
+ <view class="tabBarLineHeight"></view>
|
|
|
<view class="tabBarView">
|
|
|
<tab-bar :tabIndex="tabIndex"></tab-bar>
|
|
|
</view>
|
|
|
@@ -258,6 +262,7 @@
|
|
|
|
|
|
<script >
|
|
|
import tabBar from "../../components/tabBar/tabBar";
|
|
|
+import { saveWechatUser } from '../../api/login/login';
|
|
|
export default {
|
|
|
components: {
|
|
|
tabBar
|
|
|
@@ -267,20 +272,150 @@ export default {
|
|
|
title: 'Hello',
|
|
|
tabIndex: 4,
|
|
|
bannerList: [
|
|
|
- ,
|
|
|
+ '/static/me/u655.png',
|
|
|
],
|
|
|
+ userInfo: {
|
|
|
+ selfPhotoUrl: null
|
|
|
+ }
|
|
|
}
|
|
|
},
|
|
|
- onLoad() {
|
|
|
-
|
|
|
+ mounted() {
|
|
|
+ this.pageTop();
|
|
|
+ // 用户信息
|
|
|
+ try {
|
|
|
+ const value = uni.getStorageSync('userInfo');
|
|
|
+ if (value) {
|
|
|
+ this.userInfo = value
|
|
|
+ }
|
|
|
+ } catch (e) {
|
|
|
+ // error
|
|
|
+ }
|
|
|
+ console.log(this.userInfo, '11111111111111111111111');
|
|
|
},
|
|
|
+ // 分享到朋友圈
|
|
|
+ onShareTimeline() { },
|
|
|
+ // 分享到用户
|
|
|
+ onShareAppMessage(OBJECT) { },
|
|
|
+ onLoad() { },
|
|
|
methods: {
|
|
|
-
|
|
|
+ // 页面内容置顶
|
|
|
+ pageTop() {
|
|
|
+ uni.pageScrollTo({
|
|
|
+ scrollTop: 0,
|
|
|
+ duration: 100, // scroll animation duration in milliseconds
|
|
|
+ success: function () {
|
|
|
+ console.log('Scrolled to the top successfully');
|
|
|
+ },
|
|
|
+ fail: function (err) {
|
|
|
+ console.log('Failed to scroll to the top', err);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ // 保存微信用户信息
|
|
|
+ saveWechatUserInfo() {
|
|
|
+ let that = this;
|
|
|
+ // 保存用户信息
|
|
|
+ saveWechatUser(null, { data: this.userInfo }).then((res) => {
|
|
|
+ console.log(res.data);
|
|
|
+ }).catch(() => {
|
|
|
+ uni.showToast({
|
|
|
+ title: "操作失败"
|
|
|
+ })
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 积分详细页面
|
|
|
+ gotoIntgral() {
|
|
|
+ uni.$u.route({
|
|
|
+ url: '/pages/integral/integral',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /* 用户信息 */
|
|
|
+ perfectUserInfo() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/me/user-info',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 关于我们
|
|
|
+ aboutOur() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/me/about-our',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 设置
|
|
|
+ gotoSetting() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/setting/setting',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 服务对象管理
|
|
|
+ gotoServiceObjectMgt() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/me/service-object-mgt',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 储值服务
|
|
|
+ gotoRechargeService() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/myPages/recharge/index',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 去实名认证
|
|
|
+ gotoRealNameAuth() {
|
|
|
+ let that = this;
|
|
|
+ console.log(that.userInfo.id)
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/me/real-name-auth',
|
|
|
+ params: {
|
|
|
+ userId: that.userInfo.id
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 去优惠劵页面
|
|
|
+ gotoCoupon() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/coupon/coupon',
|
|
|
+ params: {
|
|
|
+ name: 'lisa'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 去新老系统切换
|
|
|
+ gotoSystemSwitch() {
|
|
|
+ if (this.$isDataEmpty(this.userInfo.createWay)) {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/system/system-switch',
|
|
|
+ params: {}
|
|
|
+ })
|
|
|
+ }
|
|
|
+ if (this.userInfo.createWay == 1) { // 判断是否同步过老系统
|
|
|
+ uni.showToast({
|
|
|
+ title: "你已经同步过,无需重复操作"
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
|
|
|
-<style >
|
|
|
+<style scoped lang="scss" >
|
|
|
@import '/common/css/common.css';
|
|
|
-@import './index.rpx.css';
|
|
|
+@import './index.rpx.scss';
|
|
|
</style>
|