|
@@ -0,0 +1,229 @@
|
|
|
+<template>
|
|
|
+ <view>
|
|
|
+ <cu-custom ref="Dustom"
|
|
|
+ bgImage="https://yostest175549.obs.cn-east-2.myhuaweicloud.com:443/202306151686796745663B52544232.png">
|
|
|
+ <view slot="head" class="head" :style="{ 'height': headHeight, 'top': posTop }">
|
|
|
+ <view class="custom-bar" :style="{ 'height': customBar }">
|
|
|
+ <navigator class="iconfont icon-wode-xuanzhong" url="#">
|
|
|
+
|
|
|
+ </navigator>
|
|
|
+ </view>
|
|
|
+ <navigator class="user" url="#">
|
|
|
+ <view class="profile-photo">
|
|
|
+ <view class="substitution">
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" />
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="text">
|
|
|
+ <view class="name u-line-1">
|
|
|
+ {{ userMsg.name }}
|
|
|
+ </view>
|
|
|
+ <view class="replenish">
|
|
|
+ <text class="iconfont icon-daka" style="margin-right: 10rpx;" />
|
|
|
+ {{ userMsg.phonenumber || '未填写' }}
|
|
|
+ <text style="margin: 0 20rpx;">
|
|
|
+ |
|
|
|
+ </text>
|
|
|
+ {{ userMsg.hr.position || '未知职位' }}
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </navigator>
|
|
|
+ </view>
|
|
|
+ </cu-custom>
|
|
|
+
|
|
|
+ <view class="nav-box">
|
|
|
+ <navigator class="nav-item" url="#">
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" style="margin-right: 20rpx;" />
|
|
|
+ <view>
|
|
|
+ 修改登录密码
|
|
|
+ </view>
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" />
|
|
|
+ </navigator>
|
|
|
+ <navigator class="nav-item" url="#">
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" style="margin-right: 20rpx;" />
|
|
|
+ <view>
|
|
|
+ 修改登录手机号
|
|
|
+ </view>
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" />
|
|
|
+ </navigator>
|
|
|
+ <navigator class="nav-item" url="#">
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" style="margin-right: 20rpx;" />
|
|
|
+ <view>
|
|
|
+ 绑定微信
|
|
|
+ </view>
|
|
|
+ <text class="iconfont icon-wode-xuanzhong" />
|
|
|
+ </navigator>
|
|
|
+ </view>
|
|
|
+ <u-button :customStyle="butStyle" @click="logOut()">退出登录</u-button>
|
|
|
+ </view>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+export default {
|
|
|
+ name: 'Mine',
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ headHeight: 0,
|
|
|
+ posTop: 0,
|
|
|
+ customBar: 0,
|
|
|
+ butStyle: {
|
|
|
+ position: "fixed",
|
|
|
+ bottom: '240rpx',
|
|
|
+ left: "20rpx",
|
|
|
+ width: "710rpx",
|
|
|
+ height: "90rpx",
|
|
|
+ background: "rgba(255,255,255,0.1)",
|
|
|
+ borderRadius: "8rpx",
|
|
|
+ border: "1rpx solid rgba(255,255,255,0.5)",
|
|
|
+ fontSize: "30rpx",
|
|
|
+ color: "#FFFFFF"
|
|
|
+ },
|
|
|
+ userMsg: {}
|
|
|
+ };
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.getUserMsg()
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ const Dustom = this.$refs.Dustom;
|
|
|
+ Dustom.CustomBar = Dustom.CustomBar + 94;
|
|
|
+ this.headHeight = (Dustom.CustomBar - this.StatusBar) + 'px';
|
|
|
+ this.customBar = (this.CustomBar - this.StatusBar) + 'px';
|
|
|
+ this.posTop = this.StatusBar + 'px';
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ // 获取用户信息
|
|
|
+ getUserMsg() {
|
|
|
+ this.$Http.basic({
|
|
|
+ id: 20230608105102,
|
|
|
+ content: {
|
|
|
+ nocache: true
|
|
|
+ }
|
|
|
+ }).then(res => {
|
|
|
+ if (this.cutoff(res.msg)) return;
|
|
|
+ this.userMsg = res.data;
|
|
|
+ console.log(this.userMsg)
|
|
|
+
|
|
|
+ })
|
|
|
+ },
|
|
|
+ logOut() {
|
|
|
+ uni.showModal({
|
|
|
+ title: '提示',
|
|
|
+ content: '是否确认退出登录',
|
|
|
+ success: ({ confirm }) => {
|
|
|
+ if (confirm) uni.reLaunch({
|
|
|
+ url: "/pages/login/login"
|
|
|
+ })
|
|
|
+ },
|
|
|
+ })
|
|
|
+ },
|
|
|
+ },
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss">
|
|
|
+.head {
|
|
|
+ position: fixed;
|
|
|
+ width: 100vw;
|
|
|
+ z-index: 99991;
|
|
|
+
|
|
|
+
|
|
|
+ .custom-bar {
|
|
|
+ width: 100vw;
|
|
|
+ position: relative;
|
|
|
+
|
|
|
+ .iconfont {
|
|
|
+ position: absolute;
|
|
|
+ bottom: 28rpx;
|
|
|
+ font-size: 32rpx;
|
|
|
+ color: #FFFFFF;
|
|
|
+ margin-left: 20rpx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .user {
|
|
|
+ display: flex;
|
|
|
+ height: 168rpx;
|
|
|
+ width: 100vw;
|
|
|
+ padding: 20rpx;
|
|
|
+ box-sizing: border-box;
|
|
|
+
|
|
|
+ .profile-photo {
|
|
|
+ width: 128rpx;
|
|
|
+ height: 128rpx;
|
|
|
+ border-radius: 50%;
|
|
|
+ overflow: hidden;
|
|
|
+ flex-shrink: 0;
|
|
|
+ margin-right: 20rpx;
|
|
|
+
|
|
|
+ .substitution {
|
|
|
+ width: 128rpx;
|
|
|
+ line-height: 128rpx;
|
|
|
+ text-align: center;
|
|
|
+ background: #EFF4FA;
|
|
|
+
|
|
|
+ .iconfont {
|
|
|
+ font-size: 64rpx;
|
|
|
+ color: #7C98BB;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ .text {
|
|
|
+ flex: 1;
|
|
|
+ height: 128rpx;
|
|
|
+ width: 0;
|
|
|
+
|
|
|
+ .name {
|
|
|
+ height: 48rpx;
|
|
|
+ line-height: 48rpx;
|
|
|
+ font-size: 34rpx;
|
|
|
+ color: #FFFFFF;
|
|
|
+ margin-top: 10rpx;
|
|
|
+ }
|
|
|
+
|
|
|
+ .replenish {
|
|
|
+ margin-top: 20rpx;
|
|
|
+ line-height: 40rpx;
|
|
|
+ font-size: 28rpx;
|
|
|
+ color: #FFFFFF;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.nav-box {
|
|
|
+ width: 710rpx;
|
|
|
+ margin: 20rpx auto 0;
|
|
|
+ border-radius: 8rpx;
|
|
|
+ overflow: hidden;
|
|
|
+ background: rgba($color: #fff, $alpha: 0.1);
|
|
|
+
|
|
|
+ .nav-item {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ width: 710rpx;
|
|
|
+ height: 90rpx;
|
|
|
+ padding: 0 20rpx;
|
|
|
+ box-sizing: border-box;
|
|
|
+ color: #fff;
|
|
|
+ font-size: 28rpx;
|
|
|
+
|
|
|
+ view {
|
|
|
+ flex: 1;
|
|
|
+ }
|
|
|
+
|
|
|
+ text {
|
|
|
+ flex-shrink: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+.cu-bar .content {
|
|
|
+ overflow: auto !important;
|
|
|
+}
|
|
|
+</style>
|