| | |
| | | <view class="status_bar"></view> |
| | | <!-- #endif --> |
| | | <view class="header"> |
| | | <navigator url="./setting" class="icon white iconfont iconshezhi right"></navigator> |
| | | <view class="right"> |
| | | <text class=" white iconfont iconshezhi icon" @click="toSetting"></text> |
| | | </view> |
| | | <view class="flex align-center"> |
| | | <image class="header-img ml-15" src="../../static/images/head-img.jpg"></image> |
| | | <view class="flex flex-v ml-20"> |
| | | <image class="header-img ml-10" :src="userInfo.photo?userInfo.photo:'../../static/images/default-avatar.png'"></image> |
| | | <view class="flex flex-v ml-15"> |
| | | <view> |
| | | <text class="font-18 white mr-5">222是个帅哥</text> |
| | | <text class="font-18 white mr-5">{{userInfo.name}}</text> |
| | | <text class="white icon iconfont iconxiugai"></text> |
| | | </view> |
| | | <view class="flex mt-10"> |
| | | <view class="mr-20"> |
| | | <view class="mr-20 ellipsis ellipsis-rolename"> |
| | | <text class="white mr-5 font-14">职位:</text> |
| | | <text class="white font-14">靓仔</text> |
| | | <text class="white font-14">{{userInfo.roleName}}</text> |
| | | </view> |
| | | <view> |
| | | <view class="ellipsis ellipsis-shopname"> |
| | | <text class="white mr-5 font-14">门店:</text> |
| | | <text class="white font-14">梅溪湖店</text> |
| | | <text class="white font-14">{{userInfo.shopName}}</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | name: '上月' |
| | | }, |
| | | ], |
| | | userAchieve: {} |
| | | userAchieve: {}, |
| | | userInfo: {} |
| | | } |
| | | }, |
| | | onShow() { |
| | | this.getUserAchieve() |
| | | this.getUserAchieve(); |
| | | this.getUserInfo(); |
| | | }, |
| | | methods: { |
| | | getUserInfo(){ |
| | | this.$httpUtils.request('/api/user/findUserAchieve/'+this.type).then((res) => { |
| | | if(res.status == 200){ |
| | | let {achieve} = res.mapInfo; |
| | | this.userAchieve = achieve || {}; |
| | | } |
| | | }) |
| | | let roleInfo = this.$httpUtils.getRoleInfo(); |
| | | this.userInfo = roleInfo || {}; |
| | | }, |
| | | getUserAchieve(){ |
| | | this.$httpUtils.request('/api/user/findUserAchieve/'+this.type).then((res) => { |
| | |
| | | }) |
| | | }, |
| | | tabChange(e){ |
| | | console.log(e) |
| | | this.type = e + 1; |
| | | this.getUserAchieve() |
| | | }, |
| | | toSetting(){ |
| | | let isLogin = (JSON.stringify(this.userInfo) !== '{}')?1:0; |
| | | uni.navigateTo({ |
| | | url: './setting?isLogin='+isLogin |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | background: #518EFF; |
| | | border-bottom-left-radius: 20px; |
| | | border-bottom-right-radius: 20px; |
| | | padding: 15px; |
| | | padding: 15px 10px; |
| | | } |
| | | .icon { |
| | | font-size: 18px; |
| | |
| | | width: 64px; |
| | | height: 64px; |
| | | border-radius: 50%; |
| | | flex: 0 0 64px; |
| | | } |
| | | .content{ |
| | | padding: 0 10px; |
| | |
| | | background: #FFFFFF; |
| | | font-size: 15px; |
| | | } |
| | | .ellipsis{ |
| | | color: #FFFFFF; |
| | | overflow: hidden; |
| | | text-overflow:ellipsis; |
| | | white-space: nowrap; |
| | | } |
| | | .ellipsis-rolename{ |
| | | max-width: 125px; |
| | | } |
| | | .ellipsis-shopname{ |
| | | max-width: 90px; |
| | | } |
| | | </style> |