文件上传功能添加,注意使用Path.Combine处理通用路径问题(windows||docker)

This commit is contained in:
owenchen committed 2026-09-03 16:09:54 +08:00
1 parent 7817c5374c
commit 244b59a3fb
135 files changed
+16937 -75

No files matched your search

@@ -1,20 +1,21 @@
using ClosedXML.Excel;
using CloudBuilder.Core.DatabaseAccessor.Entity;
using CloudBuilder.Core.Extensions;
using CloudBuilder.Core.Policy;
using CloudBuilder.Core.Service;
using DocumentFormat.OpenXml.Spreadsheet;
using DocumentFormat.OpenXml;
using DocumentFormat.OpenXml.Spreadsheet;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Data.SqlTypes;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;
using System.Diagnostics;
namespace CloudBuilder.Core.Report
{
@@ -179,7 +180,7 @@ CellTypeFormatOperation cellOperation, XLWorksheetOperation xLWorksheetOperation
if (service != null)
{
fileFullname = Path.Combine(service.Configuration["FileServiceSettings:ExcelOutputDirectory"], $"{DateTime.Now.ToString("yyyyMMdd")}", typeof(T).Name + $"{DateTime.Now.ToString("yyyyMMddHHmmssffff")}.xlsx");
fileFullname = Path.Combine(service.Configuration[AppsettingsPolicy.ExcelOutputDirectory], $"{DateTime.Now.ToString("yyyyMMdd")}", typeof(T).Name + $"{DateTime.Now.ToString("yyyyMMddHHmmssffff")}.xlsx");
}
using (var excel = new XLWorkbook())