From e1b028d486713eaf55aaf35fbf334aa568059c0d Mon Sep 17 00:00:00 2001
From: wwf <1971391498@qq.com>
Date: 星期二, 14 四月 2026 15:46:54 +0800
Subject: [PATCH] 项目复制
---
src/views/h5/index.vue | 34 ++++++++++++++++++++++++++++++++++
1 files changed, 34 insertions(+), 0 deletions(-)
diff --git a/src/views/h5/index.vue b/src/views/h5/index.vue
new file mode 100644
index 0000000..fd2c39d
--- /dev/null
+++ b/src/views/h5/index.vue
@@ -0,0 +1,34 @@
+<template>
+ <div v-if="userInfo.id">
+ <router-view></router-view>
+ </div>
+</template>
+<script>
+import { useSessionStore } from '@/stores/session.js'
+import { storeToRefs } from 'pinia';
+export default {
+ setup() {
+ const { setUserInfo } = useSessionStore()
+ const { userInfo } = storeToRefs(useSessionStore())
+ return { setUserInfo, userInfo }
+ },
+ data() {
+ return {}
+ },
+ created() {
+ if (this.$route.path == '/h5/verify' && this.$route.query.appId) {
+ localStorage.setItem('verify_url', this.$route.fullPath)
+ }
+ this.getUserInfo()
+ },
+ methods: {
+ getUserInfo() {
+ this.$axios.get('/system/auth/staff/profile').then(res => {
+ if (res.data.code == 0) {
+ this.setUserInfo(res.data.data || {})
+ }
+ })
+ },
+ }
+}
+</script>
\ No newline at end of file
--
Gitblit v1.8.0