style:api文件配置化
Showing
5 changed files
with
9 additions
and
8 deletions
1 | /* | 1 | /* |
2 | * @Description: 数据上报模块api文件 | 2 | * @Description: 数据上报模块api文件 |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-03-03 14:38:57 | 4 | * @LastEditTime: 2023-03-21 16:21:31 |
5 | */ | 5 | */ |
6 | /* 引入axios请求文件 */ | 6 | /* 引入axios请求文件 */ |
7 | import request from '@/utils/request' | 7 | import request from '@/utils/request' |
8 | /* 引入配置 */ | 8 | /* 引入配置 */ |
9 | import SERVER from './config' | 9 | let SERVER = JSON.parse(localStorage.getItem('ApiUrl')) |
10 | const urlHeader = SERVER.SERVERAPI + '/rest/sjsb/DataReport/' | 10 | const urlHeader = SERVER.SERVERAPI + '/rest/sjsb/DataReport/' |
11 | 11 | ||
12 | /** | 12 | /** | ... | ... |
1 | import Vue from 'vue' | ||
2 | import request from '@/utils/request' | 1 | import request from '@/utils/request' |
3 | import SERVER from './config' | 2 | // import SERVER from './config' |
3 | let SERVER = JSON.parse(localStorage.getItem('ApiUrl')) | ||
4 | // 获取用户信息 | 4 | // 获取用户信息 |
5 | export function getUserInfo () { | 5 | export function getUserInfo () { |
6 | return request({ | 6 | return request({ | ... | ... |
... | @@ -42,7 +42,6 @@ const actions = { | ... | @@ -42,7 +42,6 @@ const actions = { |
42 | item.path = JSON.parse(item.metadata)?.path || '/' | 42 | item.path = JSON.parse(item.metadata)?.path || '/' |
43 | if (!item.parentId) { | 43 | if (!item.parentId) { |
44 | item.component = Layout | 44 | item.component = Layout |
45 | console.log(item.component); | ||
46 | } else { | 45 | } else { |
47 | item.component = loadView(item.uri) | 46 | item.component = loadView(item.uri) |
48 | } | 47 | } | ... | ... |
-
Please register or sign in to post a comment