add 增加新表格 城市更新0318
This commit is contained in:
@@ -28,6 +28,14 @@ namespace TempTask.WebEntry.ApiController.Dto
|
||||
/// </summary>
|
||||
public class NumZjExcel
|
||||
{
|
||||
/// <summary>
|
||||
/// 是否采用Excel的新配置方式
|
||||
/// </summary>
|
||||
public bool is_excel_config { get; set; } = false;
|
||||
///// <summary>
|
||||
///// Excel新配置方式文件路径
|
||||
///// </summary>
|
||||
//public string excel_config_path { get; set; }
|
||||
/// <summary>
|
||||
/// sheet编号 从1开始
|
||||
/// </summary>
|
||||
@@ -82,7 +90,7 @@ namespace TempTask.WebEntry.ApiController.Dto
|
||||
/// 跳过行 集合 行留空
|
||||
/// </summary>
|
||||
public List<string> skip_columns { get; set; }
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
|
||||
@@ -30,8 +30,7 @@ namespace TempTask.WebEntry.ApiController
|
||||
{
|
||||
var configs = App.GetConfig<NumZjConfig>("NumZjConfig");
|
||||
var current = configs.numZjExcels.Find(a => (int)a.excel_no == numZjDownloadInput.type);
|
||||
//var sheet_names = new Dictionary<int, string> { { 4, "房地产业分行业(项目信息)" }, { 5, "分地区(项目信息)" } };
|
||||
var filepath = NumZjHelper.WriteTemplate(numZjDownloadInput.year, numZjDownloadInput.month, numZjDownloadInput.week, current.excel_no, current.sheets);
|
||||
var filepath = NumZjHelper.WriteTemplate(numZjDownloadInput.year, numZjDownloadInput.month, numZjDownloadInput.week, current);
|
||||
return new FileStreamResult(new FileStream(filepath, FileMode.Open), "application/octet-stream") { FileDownloadName = current.excel_name };
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user