diff --git a/WebApi_data_value/Controllers/ParkingLogsController.cs b/WebApi_data_value/Controllers/ParkingLogsController.cs index cbfb0ec..5e74035 100644 --- a/WebApi_data_value/Controllers/ParkingLogsController.cs +++ b/WebApi_data_value/Controllers/ParkingLogsController.cs @@ -56,7 +56,7 @@ namespace WebApi_data_value.Controllers return Ok(parkingLog); } - // 下載即時車位 Excel 檔案 + #region 下載即時車位 Excel 檔案 [HttpGet("DownloadCurrentStatusExcel")] public async Task DownloadCurrentStatusExcel() { @@ -117,9 +117,9 @@ namespace WebApi_data_value.Controllers } } } + #endregion - - // 下載 Excel 檔案 + #region 下載 Excel 檔案 [HttpGet("DownloadExcel")] public async Task DownloadExcel(DateTime startDate, DateTime endDate, string interval) { @@ -192,10 +192,12 @@ namespace WebApi_data_value.Controllers return File(content, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", fileName); } } + } + #endregion - // 自動下載 Excel 檔案 + #region 自動下載 Excel 檔案 [HttpGet("AutoDownloadExcel")] public async Task AutoDownloadExcel() { @@ -263,17 +265,12 @@ namespace WebApi_data_value.Controllers string fileName = $"停車紀錄-{currentDate}-{weekDay}.xlsx"; return File(content, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", fileName); - } - } - } + } + } + } + #endregion - - - - - - - // 獲取停車紀錄 + #region 獲取停車紀錄 private async Task GetParkingLogs(DateTime startDate, DateTime endDate, int pageNumber, int pageSize) { @@ -398,6 +395,7 @@ namespace WebApi_data_value.Controllers }); } } + #endregion } }