Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
client
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a664dcc2
authored
Aug 01, 2025
by
lijinqi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调用banner接口
parent
3894a0b7
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
2 deletions
+6
-2
.env.development
+1
-1
src/api/home.js
+1
-1
src/permission.js
+4
-0
No files found.
.env.development
View file @
a664dcc2
...
@@ -5,4 +5,4 @@ VITE_APP_TITLE = 先进计算普惠算力公共服务平台
...
@@ -5,4 +5,4 @@ VITE_APP_TITLE = 先进计算普惠算力公共服务平台
VITE_APP_ENV = 'development'
VITE_APP_ENV = 'development'
# 先进计算普惠算力公共服务平台/开发环境
# 先进计算普惠算力公共服务平台/开发环境
VITE_APP_BASE_API = 'http://
43.139.100.220:48081
/app-api/'
VITE_APP_BASE_API = 'http://
localhost:48080
/app-api/'
src/api/home.js
View file @
a664dcc2
...
@@ -3,7 +3,7 @@ import request from '@/utils/request'
...
@@ -3,7 +3,7 @@ import request from '@/utils/request'
// 获取首页banner
// 获取首页banner
export
function
banner
(
query
)
{
export
function
banner
(
query
)
{
return
request
({
return
request
({
url
:
'/
api/v1/banner
'
,
url
:
'/
biz/banner-info/get
'
,
method
:
'get'
,
method
:
'get'
,
params
:
query
params
:
query
})
})
...
...
src/permission.js
View file @
a664dcc2
...
@@ -4,6 +4,7 @@ import NProgress from 'nprogress'
...
@@ -4,6 +4,7 @@ import NProgress from 'nprogress'
import
'nprogress/nprogress.css'
import
'nprogress/nprogress.css'
import
{
getToken
}
from
'@/utils/auth'
import
{
getToken
}
from
'@/utils/auth'
import
useSettingsStore
from
'@/store/modules/settings'
import
useSettingsStore
from
'@/store/modules/settings'
import
useUserStore
from
"@/store/modules/user.js"
;
NProgress
.
configure
({
showSpinner
:
false
})
NProgress
.
configure
({
showSpinner
:
false
})
...
@@ -40,6 +41,9 @@ router.beforeEach((to, from, next) => {
...
@@ -40,6 +41,9 @@ router.beforeEach((to, from, next) => {
next
(
`/login?redirect=
${
to
.
fullPath
}
`
)
next
(
`/login?redirect=
${
to
.
fullPath
}
`
)
NProgress
.
done
()
NProgress
.
done
()
return
return
}
else
{
useUserStore
().
getInfo
().
then
(
res
=>
{
})
}
}
// 3. 已登录访问非白名单路由,直接放行(不做权限检查)
// 3. 已登录访问非白名单路由,直接放行(不做权限检查)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment