Ejemplo n.º 1
0
        public async Task <IActionResult> OnPostAsync(int?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var result = await _noteClient.Delete(id);

            if (result)
            {
                return(RedirectToPage("./Index"));
            }
            else
            {
                return(Page());
            }
        }