예제 #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            lineworkinfo lineworkinfo = db.lineworkinfoSet.Find(id);

            db.lineworkinfoSet.Remove(lineworkinfo);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
예제 #2
0
 public ActionResult Edit([Bind(Include = "Id,code,name,sampletime,totalnum,finishnum,errornum,bulidtime,lineinfoSetId")] lineworkinfo lineworkinfo)
 {
     if (ModelState.IsValid)
     {
         db.Entry(lineworkinfo).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.lineinfoSetId = new SelectList(db.lineinfoSet, "Id", "code", lineworkinfo.lineinfoSetId);
     return(View(lineworkinfo));
 }
예제 #3
0
        // GET: lineworkinfoes/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            lineworkinfo lineworkinfo = db.lineworkinfoSet.Find(id);

            if (lineworkinfo == null)
            {
                return(HttpNotFound());
            }
            return(View(lineworkinfo));
        }
예제 #4
0
        // GET: lineworkinfoes/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            lineworkinfo lineworkinfo = db.lineworkinfoSet.Find(id);

            if (lineworkinfo == null)
            {
                return(HttpNotFound());
            }
            ViewBag.lineinfoSetId = new SelectList(db.lineinfoSet, "Id", "code", lineworkinfo.lineinfoSetId);
            return(View(lineworkinfo));
        }