public IHttpActionResult DeleteMandateModel(int id)
        {
            var m = sm.GetMandate(id);

            if (m == null)
            {
                return(NotFound());
            }
            sm.DeleteMandate(m);
            return(Ok());
        }
Beispiel #2
0
        public ActionResult DeleteConfirmed(int id)
        {
            var mandate = s.GetMandates().ToList().Where(e => e.MandateId == id).FirstOrDefault();

            //var mandate = mandates.FirstOrDefault(e => e.MandateId.Equals(id));


            s.DeleteMandate(mandate);
            //db.MandateModels.Add(mandateModel);
            s.Commit();
            return(RedirectToAction("Index"));
        }