添加扫码签到功能和相关配置

This commit is contained in:
future
2026-06-03 16:26:44 +08:00
committed by liwentao
parent 68733acc72
commit 26e185a804
8 changed files with 1482 additions and 6 deletions
+24
View File
@@ -0,0 +1,24 @@
import { defineConfig } from 'vite'
import uni from '@dcloudio/vite-plugin-uni'
import path from 'path'
// 用来匹配地址,解决跨域问题
export default defineConfig({
plugins: [uni()],
resolve: {
alias: {
'@': path.resolve(__dirname, 'src')
},
},
server: {
proxy: {
// 匹配所有 /api 开头的请求
'/api': {
target: 'http://192.168.43.89:8084', // 你的后端SpringBoot地址
changeOrigin: true, // 开启跨域伪装
// rewrite: (path) => path.replace(/^\/areyouok/, '')
// 举例:前端请求 /api/login → 代理成 http://localhost:8088/login
}
}
}
})