项目下载影像

This commit is contained in:
2025-05-26 16:37:41 +08:00
parent 44536b803f
commit 1f157bd1a2
5 changed files with 195 additions and 1 deletions
@@ -69,6 +69,15 @@ public static class FileStoreHelper
return rootFolder;
}
public static string GetDonwnloadImageFolder(IWebHostEnvironment _hostEnvironment)
{
var rootPath = GetIRaCISRootPath(_hostEnvironment);
var rootFolder = Path.Combine(rootPath, StaticData.Folder.DownloadIamgeFolder);
return rootFolder;
}
//根据相对路径 获取具体文件物理地址
public static string GetPhysicalFilePath(IWebHostEnvironment _hostEnvironment, string relativePath)
{
+5 -1
View File
@@ -360,7 +360,11 @@ public class OSSService : IOSSService
public async Task DownLoadFromOSSAsync(string ossRelativePath, string localFilePath)
{
GetObjectStoreTempToken();
if (isFirstCall)
{
GetObjectStoreTempToken();
isFirstCall = false;
}
ossRelativePath = ossRelativePath.TrimStart('/');
try