Esempio n. 1
0
        public async Task <IHttpActionResult> DeleteTeam(TeamIdModel team)
        {
            if (!ModelState.IsValid)
            {
                return(InternalServerError());
            }
            try
            {
                await services.Remove(team);

                return(Ok());
            }
            catch (Exception ex)
            {
                return(InternalServerError(ex));
            }
        }
Esempio n. 2
0
        public async Task <ActionResult> Delete(TeamIdModel team)
        {
            await teamService.Remove(team);

            return(RedirectToAction("Index"));
        }