public void Excute() { Console.WriteLine("隊列任務"); EmployeesService = new EmployeesService(); var result = EmployeesService.GetAll(); Console.WriteLine($"資料筆數:{result.Count}"); }
// GET: Admin/AdminEmployees public ActionResult Index() { var modelView = new AdminEmployeesViewModel { ListEmployees = _employeesService.GetAll() }; return(View(modelView)); }
public ActionResult OnlineOrder() { var modelView = new EmployeesViewModel { employeesRoles = _employeesRoleService.GetAll(), employees = _employeesService.GetAll(), }; return(PartialView(modelView)); }
public ActionResult <IEnumerable <Employee> > Get() { try { var employees = db.GetAll().ToList(); return(employees); } catch (Exception ex) { throw ex; } }
public IActionResult Get() { try { IEnumerable <Employee> employees = _employeesService.GetAll(); // If no employees are found, returns 404. if (!employees.Any()) { return(NotFound()); } return(Ok(new GetAllEmployeesResponse { Employees = employees })); } catch (Exception ex) { _logger.LogError(ex, "Error on getting all employees"); throw ex; } }
public IActionResult Employee() { return(View(_employeesService.GetAll())); }
public IEnumerable <Employee> GetAll() { return(employeesServiceDelegate.GetAll()); }
public IActionResult Index() { //return Content("Hello from home controller"); return(View(_employeesService.GetAll())); }
public IEnumerable <Employee> GetAll() => _employeesService.GetAll();
[AllowAnonymous] //просматривать список могут все public IActionResult Employees() { return(View(_employees.GetAll().ToView())); }
public IEnumerable <EmployeeEntity> Get() { Logger.LogDebug("Made it past cache...fetching data"); return(EmployeesService.GetAll()); }
public IEnumerable <Employee> GetAll() { return(_employeesService.GetAll()); }
public IActionResult EmployeeList() { var employees = _mapper.Map <IEnumerable <EmployeeViewModel> >(_employeesService.GetAll()); return(View(employees)); }
public async Task <IActionResult> Get() { var clients = await _employeesService.GetAll(); return(Ok(clients)); }