Пример #1
0
        public async Task <FileResult> ExcelExport()
        {
            var filename = "excel.xls";

            string[] listTitle = { "序号", "英文名", "中文名", "最后操作时间" };
            var      list      = await _roleInfoService.RoleInfoList(new TableInputDto());

            var stream = ExcelHelper.ListExportMemoryStream(list.TableData, listTitle);

            return(File(stream, "application/vnd.ms-excel", filename));
        }
Пример #2
0
        public async Task <IActionResult> RoleInfolistAsync(TableInputDto dto)
        {
            var res = await _roleInfoService.RoleInfoList(dto);

            return(Ok(res));
        }