修复:文件预览路径错误
This commit is contained in:
parent
9f502434e5
commit
6587a22d8c
@ -406,7 +406,7 @@ public class SysFileService : IDynamicApiController, ITransient
|
||||
var host = CommonUtil.GetLocalhost();
|
||||
if (!host.EndsWith('/'))
|
||||
host += "/";
|
||||
newFile.Url = $"/sysFile/preview/{newFile.Id}";
|
||||
newFile.Url = $"/api/sysFile/preview/{newFile.Id}";
|
||||
}
|
||||
await _sysFileRep.AsInsertable(newFile).ExecuteCommandAsync();
|
||||
return newFile;
|
||||
|
||||
@ -76,7 +76,7 @@ export const useUserInfo = defineStore('userInfo', {
|
||||
idCardNum: d.idCardNum,
|
||||
email: d.email,
|
||||
accountType: d.accountType,
|
||||
avatar: d.avatar ?? '/Upload/logo.png',
|
||||
avatar: d.avatar ?? '/upload/logo.png',
|
||||
address: d.address,
|
||||
signature: d.signature,
|
||||
orgId: d.orgId,
|
||||
|
||||
@ -69,6 +69,10 @@ const viteConfig = defineConfig((mode: ConfigEnv) => {
|
||||
target: env.VITE_API_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'^/api': {
|
||||
target: env.VITE_API_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
build: {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user