Esempio n. 1
0
        public async Task <ActionResult> Delete(int Id)
        {
            var deleteResult = await _statusRepository.DeleteAsync(Id);

            ViewData["Message"] = deleteResult.Message;
            ViewData["Success"] = deleteResult.Success;
            return(RedirectToAction(nameof(this.Index)));
        }
Esempio n. 2
0
 public async Task Delete(int id)
 {
     try
     {
         await _statusRepository.DeleteAsync(id);
     }
     catch (Exception)
     {
         return;
     }
 }