// GET: Developers/Delete/5 public async Task <IActionResult> Search(SearchObjectDevelopers searchObject) { var pageSize = 10; var model = await _developerService.Search(searchObject); return(View("~/Views/Developers/Index.cshtml", PaginatedList <Developer, SearchObjectDevelopers> .Create(model, 1, pageSize, searchObject))); }
// GET: Developers public async Task <IActionResult> Index(int?pageNumber) { var pageSize = 10; var model = await _developerService.GetAllDevelopers(pageNumber, pageSize); SearchObjectDevelopers searchObject = new SearchObjectDevelopers(); return(View(PaginatedList <Developer, SearchObjectDevelopers> .Create(model, pageNumber ?? 1, pageSize, searchObject))); }
public async Task <IActionResult> Search(SearchObjectDevelopers searchObject) { try { var model = await _developerService.Search(searchObject); return(Ok(model)); } catch (Exception ex) { return(BadRequest(ex.Message)); } }
public async Task <IEnumerable <Developer> > SearchAsync(SearchObjectDevelopers searchObject) { return(await _dbContext.Developers .Where(developer => developer.Name.Contains(searchObject.Name)) .ToListAsync()); }
public async Task <IEnumerable <Developer> > SearchAsync(SearchObjectDevelopers searchObject) { return(await _repository.SearchAsync(searchObject)); }
public async Task <IEnumerable <Developer> > Search(SearchObjectDevelopers searchObject) { return(await _businessLogicDevelopers.SearchAsync(searchObject)); }