Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker 部署到本地后,打开后台页面登录,后台页面显示为空白 #251

Open
Kennytian opened this issue Jul 23, 2021 · 2 comments

Comments

@Kennytian
Copy link

Access to script at 'http://127.0.0.1:8080/static/navbar/js/app.js' from origin 'http://localhost:8080' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
system.min.js:4 GET http://127.0.0.1:8080/static/navbar/js/app.js net::ERR_FAILED
dashboard:1 Access to script at 'http://127.0.0.1:8080/static/dashboard/js/app.js' from origin 'http://localhost:8080' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
system.min.js:4 GET http://127.0.0.1:8080/static/dashboard/js/app.js net::ERR_FAILED
app-errors.js:9 Uncaught dashboard: Application 'dashboard' died in status LOADING_SOURCE_CODE: Error loading http://127.0.0.1:8080/static/dashboard/js/app.js
    at HTMLScriptElement.<anonymous> (http://localhost:8080/static/plugins/systemjs/4.1.0/system.min.js:4:4496
dashboard:1 The resource http://localhost:8080/static/plugins/element-ui/2.11.1/index.js was preloaded using link preload but not used within a few seconds from the window's load event. Please make sure it has an appropriate `as` value and it is preloaded intentionally.

看起来是这两个跨域了

@aaronnew2018
Copy link

怎么解决?

@lautin89
Copy link

尝试使用127.0.0.1:8080/dr-admin,而不是localhost访问

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants