public ActionResult Edit([Bind(Include = "idQuotation,DateCompleted,Quantity,State,TypeQuotation,incidentals,Transport,TotalLabor,CustomerValue,TotalProduction")] Quotation quotation) { if (ModelState.IsValid) { db.Entry(quotation).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(quotation)); }
public ActionResult Edit([Bind(Include = "idPublication,PublicationName,Cost,PublicationDate,State,Height,Width,Depth")] Publication publication) { if (ModelState.IsValid) { db.Entry(publication).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(publication)); }
public ActionResult Edit([Bind(Include = "IDMEDIDATIPO,Nombre")] MedidaTipo medidaTipo) { if (ModelState.IsValid) { db.Entry(medidaTipo).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(medidaTipo)); }
public ActionResult Edit([Bind(Include = "IDDocumentType,DocumentTypeName")] DocumentType documentType) { if (ModelState.IsValid) { db.Entry(documentType).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(documentType)); }
public ActionResult Edit([Bind(Include = "idSuplier,SuplierName,IdCity")] Supplier supplier) { if (ModelState.IsValid) { db.Entry(supplier).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.IdCity = new SelectList(db.Cities, "IdCity", "CityName", supplier.IdCity); return(View(supplier)); }
public ActionResult Edit([Bind(Include = "idSupplie,SupplieName,idSuplier,IDMEDIDATIPO")] Supplie supplie) { if (ModelState.IsValid) { db.Entry(supplie).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.IDMEDIDATIPO = new SelectList(db.MedidaTipoes, "IDMEDIDATIPO", "Nombre", supplie.IDMEDIDATIPO); ViewBag.idSuplier = new SelectList(db.Suppliers, "idSuplier", "SuplierName", supplie.idSuplier); return(View(supplie)); }
public ActionResult Edit(DetailViews view) { if (ModelState.IsValid) { var pic = view.Image; var folder = "~/Content/Image"; if (view.ImageFile != null) { pic = FileHelper.uploadphoto(view.ImageFile, folder); pic = string.Format("{0}/{1}", folder, pic); } var detail = ToDetail(view); detail.Image = pic; db.Entry(detail).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(view)); }