Refactor API requests and update component imports

This commit is contained in:
wangqiao
2025-08-18 14:28:10 +08:00
parent 07b4d3de99
commit 9ae3abeded
91 changed files with 669 additions and 884 deletions

View File

@ -1,7 +1,7 @@
<template>
<div class="w-100% border-b-1px border-b-[#eee] border-b-solid">
<div class="relative ma-auto flex items-center py-20px w-1500px!">
<img src="@/assets/images/logo5.png" alt="图夕夕" srcset="" class="h-51px w-182px cursor-pointer" @click="router.push('/index')" />
<img src="~/assets/images/logo5.png" alt="图夕夕" srcset="" class="h-51px w-182px cursor-pointer" @click="router.push('/index')" />
<div class="ml-60px flex items-center">
<span v-for="item in navList" :key="item" class="nav" :class="props.active === item ? 'active' : ''" @click="handleClick(item)">{{ item }}</span>
</div>
@ -37,7 +37,7 @@
</div>
<div class="absolute right-10px flex items-center">
<div class="h-36px w-36px border-rd-[50%] bg-[#F5F5F5] text-center line-height-44px">
<img v-if="!isLogin" src="@/assets/images/user.png" alt="" srcset="" class="h-19px w-17px" />
<img v-if="!isLogin" src="~/assets/images/user.png" alt="" srcset="" class="h-19px w-17px" />
<img v-else :src="userStore.userInfoRes.avatar" alt="" srcset="" class="h-19px w-17px rd-50%" />
</div>
<span v-if="!isLogin" class="ml-14px cursor-pointer text-14px text-[#1A65FF] font-normal" @click="handleLogin">立即登录</span>
@ -63,11 +63,11 @@
<script setup lang="ts">
import { ref, getCurrentInstance, computed, onMounted } from 'vue'
import { Setting, SwitchButton } from '@element-plus/icons-vue'
import { page } from '@/api/upnew/index'
import { top } from '@/api/home/index'
import type { ProjectDrawStatisticAppRespVO } from '@/api/home/type'
import { page } from '~/api/upnew/index'
import { top } from '~/api/home/index'
import type { ProjectDrawStatisticAppRespVO } from '~/api/home/type'
import { Search } from '@element-plus/icons-vue'
import useUserStore from '@/store/user'
import useUserStore from '~/store/user'
const userStore = useUserStore()
const { $openLogin } = useNuxtApp()