Exemplo n.º 1
0
        public PeripheralHistory Create(PeripheralHistory peripheralhistory)
        {
            //var ePeripheral = _iDPeripheral.Create(EPeripheral(peripheral));

            //return (Peripheral(ePeripheral));
            EPeripheralHistory ePeripheralHistory = EPeripheralHistory(peripheralhistory);

            ePeripheralHistory = _iDPeripheralHistory.Create(ePeripheralHistory);
            return(PeripheralHistory(ePeripheralHistory));
        }
 public ActionResult List()
 {
     try
     {
         PeripheralHistory peripheralhistory = new PeripheralHistory();
         return(Json(_iFPeripheralHistory.List()));
     }
     catch (Exception exception)
     {
         return(Json(exception));
     }
 }
 public JsonResult Create(PeripheralHistory peripheralhistory)
 {
     try
     {
         peripheralhistory = _iFPeripheralHistory.Create(peripheralhistory);
         return(Json(""));
     }
     catch (Exception ex)
     {
         return(Json(ex));
     }
 }
 public ActionResult Edit(PeripheralHistory peripheralhistory)
 {
     try
     {
         _iFPeripheralHistory.Update(peripheralhistory);
         return(RedirectToAction("Index"));
     }
     catch (Exception ex)
     {
         return(View());
     }
 }
 public ActionResult Delete(PeripheralHistory peripheralhistory)
 {
     try
     {
         _iFPeripheralHistory.Delete(peripheralhistory);
         return(Json(""));
     }
     catch (Exception ex)
     {
         return(Json(ex));
     }
 }
 public ActionResult Update(PeripheralHistory peripheralhistory)
 {
     try
     {
         peripheralhistory = _iFPeripheralHistory.Update(peripheralhistory);
         return(Json(""));
     }
     catch (Exception ex)
     {
         return(View(ex));
     }
 }
 public ActionResult Update(int id)
 {
     try
     {
         PeripheralHistory peripheralhistory = _iFPeripheralHistory.Read(id);
         return(View(peripheralhistory));
     }
     catch (Exception ex)
     {
         return(View(new PeripheralHistory()));
     }
 }
Exemplo n.º 8
0
        private EPeripheralHistory EPeripheralHistory(PeripheralHistory peripheralhistory)
        {
            EPeripheralHistory returnEPeripheralHistory = new EPeripheralHistory
            {
                PeripheralHistoryId = peripheralhistory.PeripheralHistoryId,

                PeripheralId = peripheralhistory.PeripheralId,
                EmployeeId   = peripheralhistory.EmployeeId,
                Date         = peripheralhistory.Date,

                CreatedBy = peripheralhistory.CreatedBy,
                UpdatedBy = peripheralhistory.UpdatedBy
            };

            return(returnEPeripheralHistory);
        }
Exemplo n.º 9
0
        private PeripheralHistory PeripheralHistory(EPeripheralHistory ePeripheralHistory)
        {
            PeripheralHistory returnPeripheralHistory = new PeripheralHistory
            {
                PeripheralHistoryId = ePeripheralHistory.PeripheralHistoryId,

                PeripheralId = ePeripheralHistory.PeripheralId,
                EmployeeId   = ePeripheralHistory.EmployeeId,
                Date         = ePeripheralHistory.Date,

                CreatedBy = ePeripheralHistory.CreatedBy,
                UpdatedBy = ePeripheralHistory.UpdatedBy
            };

            return(returnPeripheralHistory);
        }
Exemplo n.º 10
0
 public void Delete(PeripheralHistory peripheralhistory)
 {
     _iDPeripheralHistory.Delete(EPeripheralHistory(peripheralhistory));
 }
Exemplo n.º 11
0
        public PeripheralHistory Update(PeripheralHistory peripheralhistory)
        {
            var ePeripheralHistory = _iDPeripheralHistory.Update(EPeripheralHistory(peripheralhistory));

            return(PeripheralHistory(ePeripheralHistory));
        }