| | |
| | | <view class="userBox"> |
| | | <view class="flex items-center pb-30rpx pl-30rpx pr-20rpx"> |
| | | <view class="mr-20rpx"> |
| | | <u-avatar :src="user.avatar || defaultAvatar" size="70" /> |
| | | <u-avatar @click="uploadAvatar" :src="user.avatar || showDefaultHeader" size="70" /> |
| | | </view> |
| | | <view class="flex-1"> |
| | | <view class="userName">{{user.nickName }}</view> |
| | |
| | | import { getDeviceRegionApi } from "@/api/map.js"; |
| | | import defaultAvatar from '/static/images/defaultAvatar.svg' |
| | | import rightImage from '@/static/images/user/rightBtn.svg'; |
| | | import showDefaultHeader from "@/static/images/user/default-header.svg"; |
| | | const { setClipboardData, getClipboardData } = useClipboard(); |
| | | // |
| | | // const rightImage = getAssetsImage("/images/user/rightBtn.svg"); |
| | |
| | | height: 100%; |
| | | } |
| | | .pageUser { |
| | | background: url("@/static/images/user/userbg.svg") no-repeat ; |
| | | background: url("@/static/images/user/userbg.svg") no-repeat; |
| | | background-size: 100%; |
| | | } |
| | | .userBox { |
| | | padding-top: 212rpx; |
| | |
| | | @confirm="onPurchaseDate" |
| | | @cancel="showPurchaseDate = false" |
| | | /> |
| | | <!-- 所属区域 --> |
| | | <u-cascader |
| | | show="show" |
| | | v-model="value" |
| | | :data="areaData" |
| | | ></u-cascader> |
| | | </u-form> |
| | | </view> |
| | | </template> |
| | | <script setup> |
| | | import { aircraftInfoSaveApi,uploadFileApi } from '@/api/index' |
| | | import { ref, computed } from 'vue' |
| | | import { aircraftInfoSaveApi,uploadFileApi,areaDataApi } from '@/api/index' |
| | | import { ref, computed, onMounted } from 'vue' |
| | | import dayjs from 'dayjs' |
| | | |
| | | const formRef = ref(null); |
| | |
| | | }); |
| | | }); |
| | | } |
| | | // 获取所属单位 |
| | | const isShowRegion = ref(false) |
| | | const areaData = ref([]) |
| | | function getAreaData() { |
| | | areaDataApi().then(res => { |
| | | if (res.data.code === 200) { |
| | | areaData.value = res.data.data |
| | | } |
| | | }) |
| | | } |
| | | // 提交图片 |
| | | function afterReadImage(event) { |
| | | // 获取上传的文件对象 |
| | |
| | | // 这里可以添加额外的失败处理逻辑 |
| | | } |
| | | } |
| | | onMounted(() => { |
| | | getAreaData() |
| | | }) |
| | | </script> |
| | | <style scoped lang="scss"> |
| | | .deviceRegistration { |
| | |
| | | <!-- 个人资料 --> |
| | | <template> |
| | | <view class="container"> |
| | | <view class="pageBg"></view> |
| | | <div class="avatarBox"> |
| | | <u-avatar @click="uploadAvatar" :src="userInfo.avatar" size="114" mode="aspectFill" /> |
| | | <u-avatar @click="uploadAvatar" :src="userInfo.avatar || showDefaultHeader" size="114" mode="aspectFill" /> |
| | | </div> |
| | | <view class="detailBox"> |
| | | <div class="detailCon"> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">姓名</div> |
| | | <div>{{userInfo.realName}}</div> |
| | | <div>{{userInfo.nickName}}</div> |
| | | </div> |
| | | <!-- <div class="orderRow"> |
| | | <div class="rowTitle">所属单位</div> |
| | | <div>{{userInfo.deptName}}</div> |
| | | </div> --> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">是否认证</div> |
| | | <div>{{userInfo.isAuth ? '已认证' : '未认证'}}</div> |
| | | <div class="rowTitle">认证状态</div> |
| | | <div>{{userInfo.status === 1 ? '已认证' : '未认证'}}</div> |
| | | </div> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">手机号</div> |
| | |
| | | </template> |
| | | |
| | | <script setup> |
| | | import showDefaultHeader from "@/static/images/user/default-header.svg"; |
| | | import { |
| | | getEnvObj, |
| | | getWebViewUrl |
| | |
| | | const userInfo = ref({ |
| | | id: '', |
| | | avatar: '', |
| | | realName: '', |
| | | nickName: '', |
| | | name: '', |
| | | phone: '', |
| | | email: '', |
| | |
| | | const getUserInfoData = () => { |
| | | getUserInfo().then(res => { |
| | | const user = res.data.data; |
| | | console.log('user',user) |
| | | userInfo.value = { |
| | | id: user.id, |
| | | id: user.userId, |
| | | avatar: user.avatar, |
| | | name: user.name, |
| | | realName: user.realName, |
| | | phone: user.phone, |
| | | email: user.email, |
| | | deptName: user.deptName, |
| | | nickName: user.nickName, |
| | | // realName: user.realName, |
| | | phone: user.phonenumber, |
| | | email: user.sysDept.email, |
| | | deptName: user.sysDept.deptName, |
| | | }; |
| | | |
| | | }); |
| | |
| | | width: 100%; |
| | | height: 100%; |
| | | background: url("@/static/images/user/userbg.svg") no-repeat ; |
| | | background-size: 100%; |
| | | } |
| | | .avatarBox { |
| | | width: 228rpx; |
| | |
| | | height: 100rpx !important; |
| | | } |
| | | .note { |
| | | position: absolute; |
| | | bottom: 400rpx; |
| | | font-family: Source Han Sans CN, Source Han Sans CN; |
| | | font-weight: 400; |
| | | font-size: 10px; |
| | |
| | | </div> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">密码</div> |
| | | <input type="password" v-model="passwordForm.password" placeholder="请输入" class="input-item" /> |
| | | <input type="password" v-model="passwordForm.password" placeholder="请输入新密码" class="input-item" /> |
| | | |
| | | </div> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">确认密码</div> |
| | | <input type="password" v-model="passwordForm.password2" placeholder="请输入" class="input-item" /> |
| | | <input type="password" v-model="passwordForm.password2" placeholder="请输入确认密码" class="input-item" /> |
| | | </div> |
| | | <div class="orderRow"> |
| | | <div class="rowTitle">验证码</div> |
| | | <input type="text" v-model="passwordForm.code" placeholder="请输入验证码" class="input-item" /> |
| | | <u-button :disabled="countDown > 0" @click="sendVerificationCode" type="primary" color="#007AFF"> |
| | | <u-button class="getCode" :disabled="countDown > 0" @click="sendVerificationCode" type="primary" color="#007AFF"> |
| | | {{ countDown > 0 ? `${countDown}s后重发` : '获取验证码' }} |
| | | </u-button> |
| | | </div> |
| | |
| | | width: 100%; |
| | | height: 100%; |
| | | background: url("@/static/images/user/userbg.svg") no-repeat ; |
| | | background-size: 100%; |
| | | } |
| | | |
| | | .detailBox { |
| | |
| | | width: 276rpx !important; |
| | | height: 100rpx !important; |
| | | } |
| | | .getCode { |
| | | margin-left: 20rpx; |
| | | width: 180rpx; |
| | | } |
| | | </style> |