public async Task <IActionResult> GetAll() { var result = await _services.GetAllAsync(); if (result.IsValid) { return(Ok(result.Result)); } return(BadRequest(result.ErrorsList)); }
public async Task <IActionResult> Index() { var result = await _services.GetAllAsync(); if (result.IsValid) { return(View(result.Result)); } TempData["ErrorsList"] = result.ErrorsList; return(View()); }
public async Task <SelectList> GetCultural(string hashIdSelectedValue = null) { var cultural = await _culturalService.GetAllAsync(); return(cultural.IsValid ? new SelectList(cultural.Result, "HashId", "Name", hashIdSelectedValue) : null); }
public async Task <IActionResult> Index() { var result = await _services.GetAllAsync(); return(View(result.Result)); }
public async Task <IActionResult> GetAll() { return(Ok(await _services.GetAllAsync())); }