Пример #1
0
        public ActionResult CabRoute(tbCabRoute cabroute)
        {
            AdminService _service = new AdminService();
            if (_service.SetRoute(cabroute))

                return View(cabroute);
            return View("Error");
        }
Пример #2
0
        public ActionResult CabRoute(tbCabRoute cabroute)
        {
            AdminService _service = new AdminService();

            if (_service.SetRoute(cabroute))
            {
                return(View(cabroute));
            }
            return(View("Error"));
        }
Пример #3
0
 public bool SetRoute(tbCabRoute cabroute)
 {
     try
     {
         _dataContext.tbCabRoutes.InsertOnSubmit(cabroute);
         _dataContext.SubmitChanges();
     }
     catch (Exception e)
     {
         return(false);
     }
     return(true);
 }
Пример #4
0
 public bool SetRoute(tbCabRoute cabroute)
 {
     return _repository.SetRoute(cabroute);
 }
Пример #5
0
 public bool SetRoute(tbCabRoute cabroute)
 {
     return(_repository.SetRoute(cabroute));
 }
Пример #6
0
        public bool SetRoute(tbCabRoute cabroute)
        {
            try
            {
                _dataContext.tbCabRoutes.InsertOnSubmit(cabroute);
                _dataContext.SubmitChanges();

            }
            catch (Exception e)
            {
                return false;
            }
            return true;
        }