culture/src/utils/baseurl.js
@@ -1,3 +1,8 @@ function getProductionFileUrl() { if (typeof window === 'undefined') return '/images/'; return `${window.location.protocol}//${window.location.hostname}:11223/images/`; } const apiConfig = { // 开发环境 development: { @@ -9,7 +14,7 @@ production: { baseURL: "/culture", imgUrl: "/culture/open/file/upload", showImgUrl:'http://127.0.0.1:11223/images/' showImgUrl: getProductionFileUrl() }, };