public async Task <IActionResult> OnPostAsync(int id) { HeadJew = _headJewService.GetHeadJew(id); await _headJewService.DeleteHeadJewAsync(HeadJew.JewelryID); return(RedirectToPage("AllHeadJew")); }
public IActionResult OnGet(int id) { HeadJew = _headJewService.GetHeadJew(id); if (HeadJew == null) { RedirectToPage("/NotFound"); } return(Page()); }