예제 #1
0
        public IActionResult ExportExcel(HospitalListVM vm)
        {
            vm.SearcherMode = vm.Ids != null && vm.Ids.Count > 0 ? ListVMSearchModeEnum.CheckExport : ListVMSearchModeEnum.Export;
            var data = vm.GenerateExcel();

            return(File(data, "application/vnd.ms-excel", $"Export_Hospital_{DateTime.Now.ToString("yyyy-MM-dd")}.xls"));
        }
예제 #2
0
 public string Search(HospitalListVM vm)
 {
     if (ModelState.IsValid)
     {
         return(vm.GetJson(false));
     }
     else
     {
         return(vm.GetError());
     }
 }
예제 #3
0
 public IActionResult ExportExcel(HospitalListVM vm)
 {
     return(vm.GetExportData());
 }
예제 #4
0
 public string Search(HospitalListVM vm)
 {
     return(vm.GetJson(false));
 }