Esempio n. 1
0
        public void AddProtocolResult(ArchivedProtocolResultW aprotocolResult)
        {
            aprotocolResult.Id = Guid.NewGuid();
            Db.ArchivedProtocolResults.Add(aprotocolResult.ToBase());

            Db.SaveChanges();
        }
Esempio n. 2
0
        public void EditProtocolResult(ArchivedProtocolResultW aprotocolResult)
        {
            var protocolResult = Db.ArchivedProtocolResults.Single(apr => apr.Id == aprotocolResult.Id);

            protocolResult.ResultNumber = aprotocolResult.ResultNumber;
            protocolResult.Results      = aprotocolResult.Results;

            Db.SaveChanges();
        }
        public ActionResult EditProtocolResult(ArchivedProtocolResultW aprotocolResult)
        {
            if (ModelState.IsValid)
            {
                _rep.EditProtocolResult(aprotocolResult);
                return(RedirectToAction("ProtocolResultsIndex", new { aproductTestId = aprotocolResult.ArchivedProductTestId }));
            }

            return(View(aprotocolResult));
        }