From d882110d4e70aba7ccb25b026ddf54a0fe5632a9 Mon Sep 17 00:00:00 2001 From: zhengyuxuan <zhengyuxuan1995> Date: 星期一, 31 三月 2025 14:32:26 +0800 Subject: [PATCH] fix:新增导出接口 --- LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs | 39 ++++++++++++++++++++++++++++++++++++++- 1 files changed, 38 insertions(+), 1 deletions(-) diff --git a/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs b/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs index 96e2a15..b25cbc7 100644 --- a/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs +++ b/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs @@ -443,6 +443,33 @@ } /// <summary> + /// 鑾峰彇娓犻亾鍒嗕剑鍒嗛〉鍒楄〃 + /// </summary> + /// <param name="input"></param> + /// <returns></returns> + [HttpPost] + public async Task<PageOutput<LifePayChannlesRakeListOutput>> GetLifePayChannlesRakePage(LifePayChannlesRakePageInput input) + { + return await _lifePayOrderService.GetLifePayChannlesRakePage(input); + } + + /// <summary> + /// 瀵煎嚭娓犻亾鍒嗕剑Excel + /// </summary> + /// <param name="input"></param> + /// <returns></returns> + [HttpPost] + public async Task<ActionResult> GetLifePayChannlesRakePageExport(LifePayChannlesRakePageInput input) + { + var data = await _lifePayOrderService.GetLifePayChannlesRakePageExport(input); + if (data.Any()) + { + var bytes = ExcelHelper.ListToByteForExcel(data, "xlsx"); + return File(bytes, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "娓犻亾鍒嗕剑" + ".xlsx"); + } + return Json(default); + } + /// <summary> /// 鑾峰彇鏀舵敮娴佹按鍒嗛〉鏁版嵁 /// </summary> /// <param name="input"></param> @@ -539,7 +566,17 @@ await _lifePayOrderService.GetAllLifePayExpensesReceipts(); } - + /// <summary> + /// 鍚屾璁㈠崟 + /// </summary> + /// <returns></returns> + [HttpGet] + [AllowAnonymous] + public async Task GetAllChannlesRake() + { + await _lifePayOrderService.GetAllChannlesRake(); + } + #endregion -- Gitblit v1.9.1