From 5c48ef2b8267c38bae717202615e1618074ee31c Mon Sep 17 00:00:00 2001 From: gaoluyang <2820782392@qq.com> Date: 星期五, 29 八月 2025 15:25:05 +0800 Subject: [PATCH] 修改组件 --- src/pages_mine/pages/info/index.vue | 106 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 106 insertions(+), 0 deletions(-) diff --git a/src/pages_mine/pages/info/index.vue b/src/pages_mine/pages/info/index.vue new file mode 100644 index 0000000..dfdae6b --- /dev/null +++ b/src/pages_mine/pages/info/index.vue @@ -0,0 +1,106 @@ +<template> + <view class="container"> + <view class="card"> + <u-cell-group> + <u-cell title="鏄电О" :value="user.nickName"> + <template #icon> + <u-icon name="account" size="18" /> + </template> + </u-cell> + <u-cell title="鎵嬫満鍙风爜" :value="user.phonenumber"> + <template #icon> + <u-icon name="phone" size="18" /> + </template> + </u-cell> + <u-cell title="閭" :value="user.email"> + <template #icon> + <u-icon name="email" size="18" /> + </template> + </u-cell> + <u-cell title="宀椾綅" :value="postGroup"> + <template #icon> + <u-icon name="star" size="18" /> + </template> + </u-cell> + <u-cell title="瑙掕壊" :value="roleGroup"> + <template #icon> + <u-icon name="account-circle" size="18" /> + </template> + </u-cell> + <u-cell title="鍒涘缓鏃ユ湡" :value="user.createTime"> + <template #icon> + <u-icon name="calendar" size="18" /> + </template> + </u-cell> + </u-cell-group> + </view> + + <!-- <u-button @click="register()">缁戝畾寰俊</u-button> --> + </view> +</template> + +<script setup> +import { getUserProfile } from "@/api/system/user" +import { ref } from "vue"; +import modal from "@/plugins/modal" + +const user = ref({}) +const roleGroup = ref("") +const postGroup = ref("") +function getUser() { + getUserProfile().then(response => { + user.value = response.data + roleGroup.value = response.roleGroup + postGroup.value = response.postGroup + }) +} +getUser() + +import { wxRegister } from "@/api/oauth" +import { getWxCode } from "@/utils/geek" +function register(){ + modal.loading('缁戝畾寰俊涓�...') + getWxCode().then(res=>{ + wxRegister('miniapp',res).then(res=>{ + modal.closeLoading() + }) + }) + +} + +</script> + +<style lang="scss"> +/* 鑳屾櫙鏇存煍鍜岋紝鍗$墖鏇寸獊鍑� */ +page { + background-color: #f5f7fb; +} + +.container { + min-height: 100vh; + padding: 0; + box-sizing: border-box; +} + +/* 鍒楄〃鍗$墖瀹瑰櫒 */ +.card { + background-color: #ffffff; + box-shadow: 0 0.375rem 1rem rgba(0, 0, 0, 0.06); + overflow: hidden; +} + +/* 閫傞厤 uview-plus Cell */ +:deep(.u-cell) { + min-height: 3rem; + align-items: center; +} + +:deep(.u-cell__title) { + font-weight: 500; + color: #1f2937; +} + +:deep(.u-cell__value) { + color: #6b7280; +} +</style> -- Gitblit v1.9.3