// GET: PurchaseOrders/Details/10005 public ActionResult Details(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } var purchaseOrder = _poRepo.GetById(Convert.ToInt32(id)); if (purchaseOrder == null) { return(HttpNotFound()); } var po = new PurchaseOrderDTO(purchaseOrder); //ViewBag.PurchaseOrder = po; return(View(po)); }
public void EditPO(POs PO) { var original = pORepository.GetById(p => p.PoId == PO.PoId); pORepository.Update(original, PO.AutoMapObject <POs, DB.POs>()); }