【fix】优化代码

This commit is contained in:
黄少君
2024-02-22 18:37:23 +08:00
parent 17c043348a
commit f8fac0a5bc
246 changed files with 973 additions and 406 deletions

16
App.vue
View File

@ -1,15 +1,15 @@
<script setup>
import { createBuryPoint } from '@/api/global'
import cookie from "@/utils/cookie";
import { onLaunch } from "@dcloudio/uni-app";
import { useMainStore } from "@/store/store";
import { onLaunch, onShow } from "@dcloudio/uni-app";
import { useMainStore } from "@/store/modules/useMainStore";
const mainStore = useMainStore();
onLaunch( () => {
onLaunch(() => {
const tokenObj = cookie.get('accessToken')
let userInfo = ''
if (tokenObj && !mainStore.user) {
userInfo = mainStore.getUserInfo()
userInfo = mainStore.getUserInfo()
}
// 埋点
createBuryPoint({
@ -17,11 +17,14 @@ onLaunch( () => {
})
})
onShow(() => {
mainStore.doGetIntegralName()
})
</script>
<style lang="scss">
/*每个页面公共css */
@import "uview-plus/index.scss";
@import '@/uni_modules/uv-ui-tools/index.scss';
@import "style/style.scss";
page {
@ -29,7 +32,8 @@ page {
position: relative;
padding-bottom: constant(safe-area-inset-bottom);
padding-bottom: env(safe-area-inset-bottom);
&::after{
&::after {
content: '';
width: 100%;
height: env(safe-area-inset-bottom);