Esempio 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());
        }
Esempio 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());
        }