Exemplo n.º 1
0
        // for delete user
        public async Task <IHttpActionResult> Delete(int id)
        {
            user user = await Repo.GetEntity(id);

            if (user != null)
            {
                Repo.Delete(user);
                UOW.Save();
                return(Ok());
            }
            return(NotFound());
        }
Exemplo n.º 2
0
        // for delete task
        public async Task <IHttpActionResult> Delete(int id)
        {
            request req = await Repo.GetEntity(id);

            if (req != null)
            {
                Repo.Delete(req);
                UOW.Save();
                return(Ok());
            }
            return(NotFound());
        }