Beispiel #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            ZonalExco zonalExco = db.ZonalExco.Find(id);

            db.ZonalExco.Remove(zonalExco);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Beispiel #2
0
 public ActionResult Edit(ZonalExco zonalExco)
 {
     if (ModelState.IsValid)
     {
         db.Entry(zonalExco).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.ActiveMemberId = new SelectList(db.ActiveMember, "ActiveMemberId", "Fullname", zonalExco.ActiveMemberId);
     ViewBag.PortfolioId    = new SelectList(db.Portfolio, "Id", "PortfolioName", zonalExco.PortfolioId);
     ViewBag.ZoneId         = new SelectList(db.ZonalChapter, "Id", "ZoneName", zonalExco.ZoneId);
     return(View(zonalExco));
 }
Beispiel #3
0
        // GET: ZonalExco/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            ZonalExco zonalExco = db.ZonalExco.Find(id);

            if (zonalExco == null)
            {
                return(HttpNotFound());
            }
            return(View(zonalExco));
        }
Beispiel #4
0
        // GET: ZonalExco/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            ZonalExco zonalExco = db.ZonalExco.Find(id);

            if (zonalExco == null)
            {
                return(HttpNotFound());
            }
            ViewBag.ActiveMemberId = new SelectList(db.ActiveMember, "ActiveMemberId", "Fullname", zonalExco.ActiveMemberId);
            ViewBag.PortfolioId    = new SelectList(db.Portfolio, "Id", "PortfolioName", zonalExco.PortfolioId);
            ViewBag.ZoneId         = new SelectList(db.ZonalChapter, "Id", "ZoneName", zonalExco.ZoneId);
            return(View(zonalExco));
        }