Skip to content

Commit

Permalink
feat: 优化
Browse files Browse the repository at this point in the history
  • Loading branch information
wei-zone committed Jun 1, 2024
1 parent 6ab20e8 commit 2a0a4a6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .env.production
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 只在生产模式中被载入

# API
VITE_API_URL = https://cloud-app.com.cn/
VITE_API_URL = https://forguo.cn/api
4 changes: 2 additions & 2 deletions src/router/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import LayoutMain from '@/components/layout/LayoutMain.vue'
import { createRouter, createWebHistory, type RouteRecordRaw } from 'vue-router'
import { createRouter, createWebHashHistory, type RouteRecordRaw } from 'vue-router'
import { type RouterOptions } from 'vue-router'

// 路由集合
Expand Down Expand Up @@ -49,7 +49,7 @@ for (const componentPath in views) {
}

const router = createRouter({
history: createWebHistory(import.meta.env.BASE_URL),
history: createWebHashHistory(import.meta.env.BASE_URL),
routes: [...routes]
} as RouterOptions)
console.log(routes)
Expand Down
1 change: 1 addition & 0 deletions src/views/LoginView/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ const onFinish = async (values: any) => {
await userStore.userLogin({ ...values })
loading.value = false
} catch (e) {
loading.value = false
console.log(e)
}
}
Expand Down

0 comments on commit 2a0a4a6

Please sign in to comment.