public ActionResult Edit(TipoVehiculo tipovehiculo)
 {
     if (ModelState.IsValid)
     {
         tipovehiculo.FechaAlta = DateTime.Now;
         db.Entry(tipovehiculo).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(tipovehiculo);
 }
        public ActionResult Create(TipoVehiculo tipovehiculo)
        {
            if (ModelState.IsValid)
            {
                tipovehiculo.FechaAlta = DateTime.Now;
                tipovehiculo.UsuarioAlta = Convert.ToInt32(Session["userNameId"]);
                db.TiposVehiculo.Add(tipovehiculo);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            return View(tipovehiculo);
        }