public IActionResult OnPost(int?id) { if (id == null) { return(NotFound()); } Application = _context.Applications.First(a => a.AppId == id); if (Application != null) { _context.Remove(Application); _context.SaveChanges(); } return(RedirectToPage("./Index")); }
public IActionResult OnPost(int?id) { if (id == null) { return(NotFound()); } Dashboard = _context.Dashboards.First(d => d.DashboardId == id); if (Dashboard != null) { _context.Remove(Dashboard); _context.SaveChanges(); } return(RedirectToPage("./Index")); }