Beispiel #1
0
        public async Task <IActionResult> OnPostDeleteAsync()
        {
            var objectiveID = Objective.ID;
            var courseID    = Objective.CourseID;

            var success = await _context.DeleteObjective(objectiveID);

            if (!success)
            {
                return(RedirectToPage("/Error"));
            }

            return(RedirectToPage("./List", new { courseID }));
        }