hookehuyr

feat: 更新代理服务器地址并添加首页数据接口调用

将开发环境代理地址从oa-dev.onwall.cn更改为oa.jcedu.org
在Home.vue中添加首页数据接口调用逻辑
...@@ -16,7 +16,7 @@ VITE_ID = 13761653761 ...@@ -16,7 +16,7 @@ VITE_ID = 13761653761
16 VITE_PIN = 16 VITE_PIN =
17 17
18 # 反向代理服务器地址 18 # 反向代理服务器地址
19 -VITE_PROXY_TARGET = https://oa-dev.onwall.cn 19 +VITE_PROXY_TARGET = https://oa.jcedu.org
20 # VITE_PROXY_TARGET = http://oa.onwall.cn 20 # VITE_PROXY_TARGET = http://oa.onwall.cn
21 21
22 # PC端地址 22 # PC端地址
......
1 /* 1 /*
2 * @Date: 2023-08-24 09:42:27 2 * @Date: 2023-08-24 09:42:27
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2025-10-31 11:04:23 4 + * @LastEditTime: 2025-10-31 11:10:04
5 * @FilePath: /stdj_h5/src/api/index.js 5 * @FilePath: /stdj_h5/src/api/index.js
6 * @Description: 文件描述 6 * @Description: 文件描述
7 */ 7 */
......
...@@ -189,6 +189,9 @@ import VideoPlayer from '@/components/VideoPlayer.vue' ...@@ -189,6 +189,9 @@ import VideoPlayer from '@/components/VideoPlayer.vue'
189 import { useTitle } from '@vueuse/core'; 189 import { useTitle } from '@vueuse/core';
190 import { useRouter } from 'vue-router' 190 import { useRouter } from 'vue-router'
191 191
192 +// 导入接口
193 +import { homePageAPI } from '@/api/index.js'
194 +
192 const router = useRouter() 195 const router = useRouter()
193 196
194 // 页面标题 197 // 页面标题
...@@ -307,8 +310,13 @@ const selectStep = (index) => { ...@@ -307,8 +310,13 @@ const selectStep = (index) => {
307 } 310 }
308 311
309 // 组件挂载后计算装饰线位置 312 // 组件挂载后计算装饰线位置
310 -onMounted(() => { 313 +onMounted(async () => {
311 - calculateLinePosition() 314 + await calculateLinePosition();
315 + // 调用接口获取首页数据
316 + const { code, list } = await homePageAPI();
317 + if (code) {
318 + console.warn(list);
319 + }
312 }) 320 })
313 321
314 // 监听当前步骤变化,重新计算装饰线位置 322 // 监听当前步骤变化,重新计算装饰线位置
......