Пример #1
0
 public ActionResult Sources(int?result)
 {
     if (result.HasValue)
     {
         ViewBag.Result = ProcessResults.GetById(result.Value);
     }
     return(View(DataManager.Source.GetSources()));
 }
Пример #2
0
 public ActionResult LogIn(int?id)
 {
     if (id != null)
     {
         ViewBag.Result = ProcessResults.GetById(id.Value);
     }
     return(View());
 }
 public ActionResult AddClassification(int?result)
 {
     if (result.HasValue)
     {
         ViewBag.Result = ProcessResults.GetById(result.Value);
     }
     return(View());
 }
 public ActionResult EditConcept(int id, int?result)
 {
     if (result.HasValue)
     {
         ViewBag.Result = ProcessResults.GetById(result.Value);
     }
     return(View(DataManager.Concept.GetConcept(id)));
 }
Пример #5
0
 public ActionResult GetConcepts(int?result)
 {
     if (result.HasValue)
     {
         ViewBag.Result = ProcessResults.GetById(result.Value);
     }
     return(View(DataManager.Concept.GetConcepts(confirmed: false)));
 }
 public ActionResult AddDefinition(int id, int?result)
 {
     if (result.HasValue)
     {
         ViewBag.Result = ProcessResults.GetById(result.Value);
     }
     ViewBag.ConceptId = id;
     return(View());
 }
Пример #7
0
 public ActionResult AddBranch(int enterpriseId, int?id)
 {
     if (id != null)
     {
         ViewBag.Result = ProcessResults.GetById(id.Value);
     }
     ViewBag.EntId = enterpriseId;
     return(View());
 }
Пример #8
0
        public ActionResult Classifications(int?result)
        {
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            var f = DataManager.Classification.GetClassifications();

            return(View(DataManager.Classification.GetClassifications()));
        }
Пример #9
0
        public ActionResult Definition(int id, int?result)
        {
            var definition = DataManager.Concept.GetDefinition(id);

            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(definition));
        }
Пример #10
0
        //
        // GET: /Home/

        public ActionResult Index(int?result)
        {
            string s = HttpContext.Request.PhysicalApplicationPath;

            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View((Object)s));
        }
        public ActionResult AddSource(int?result)
        {
            var user = DataManager.DefineUser(HttpContext);

            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View());
        }
Пример #12
0
        public ActionResult LogIn(int?result)
        {
            UserModel user = DataManager.DefineUser(HttpContext);

            if (user != null)
            {
                return(RedirectToAction("Index"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View());
        }
Пример #13
0
        public ActionResult EditPlace(int placeId, int?result)
        {
            var user = DefineUser(HttpContext);

            if (HasNoAccess(user))
            {
                return(RedirectToAction("NoPermission"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(DataManager.Places.GetPlace(placeId)));
        }
Пример #14
0
        public ActionResult AddCountry(int?result)
        {
            var user = DefineUser(HttpContext);

            if (HasNoAccess(user))
            {
                return(RedirectToAction("NoPermission"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View());
        }
Пример #15
0
        public ActionResult AddBrand(int?result)
        {
            var user = DefineUser();

            if (HasNoAccess(user))
            {
                return(NoPermission());
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View());
        }
Пример #16
0
        public ActionResult EditBrand(int id, int?result)
        {
            var user = DefineUser();

            if (HasNoAccess(user))
            {
                return(NoPermission());
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(DataManager.Cars.GetBrand(id)));
        }
Пример #17
0
        public ActionResult EditModel(int?result, int id)
        {
            var user = DefineUser();

            if (HasNoAccess(user))
            {
                return(NoPermission());
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(Tuple.Create(DataManager.Cars.GetCarModel(id), DataManager.Cars.BodyClasses)));
        }
Пример #18
0
        public ActionResult Region(int?result, int regionId)
        {
            var user = DefineUser(HttpContext);

            if (HasNoAccess(user))
            {
                return(RedirectToAction("NoPermission"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(DataManager.Regions.GetRegion(regionId)));
        }
Пример #19
0
        public ActionResult DeleteCountry(int id, int?result)
        {
            var user = DefineUser(HttpContext);

            if (HasNoAccess(user))
            {
                return(RedirectToAction("NoPermission"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(DataManager.Countries.GetCountry(id)));
        }
Пример #20
0
        public ActionResult Users(int?result)
        {
            var user = DefineUser(HttpContext);

            if (HasNoAccess(user))
            {
                return(RedirectToAction("NoPermission"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            ViewBag.User = user;
            return(View(DataManager.Users.GetAll()));
        }
Пример #21
0
        public ActionResult Model(int?result, int id)
        {
            var user = DefineUser();

            if (HasNoAccess(user))
            {
                return(NoPermission());
            }
            //if (id <= 0) return View(DataManager.Cars.Modifications());
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(DataManager.Cars.GetCarModel(id)));
        }
Пример #22
0
        public ActionResult Registration(int?result)
        {
            UserModel user = DataManager.DefineUser(HttpContext);

            if (user != null)
            {
                return(RedirectToAction("Index"));
            }
            ViewBag.Groups = DataManager.University.GetGroups();
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View());
        }
Пример #23
0
        public ActionResult LogIn(int?result)
        {
            User user = DefineUser(HttpContext);

            if (user != null)
            {
                return(RedirectToAction("Index"));
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            Culture culture = DefineLanguage(HttpContext);

            ViewBag.Culture = culture;
            return(View());
        }
Пример #24
0
        public ActionResult EditModification(int?result, int id)
        {
            var user = DefineUser();

            if (HasNoAccess(user))
            {
                return(NoPermission());
            }
            if (result.HasValue)
            {
                ViewBag.Result = ProcessResults.GetById(result.Value);
            }
            return(View(new EditModificationModel(
                            DataManager.Cars.GetModification(id),
                            DataManager.Cars.EngineLocations,
                            DataManager.Cars.ValvesArrangements,
                            DataManager.Cars.FuelTypes,
                            DataManager.Cars.BatteryTypes,
                            DataManager.Cars.TransmissionTypes,
                            DataManager.Cars.TireCarcassTypes)));
        }