Exemple #1
0
        public ActionResult TouristicContentList(TouristicContentType type)
        {
            var dbContext = new ApplicationDbContext();

            var model = new TouristicContentsListViewModel
            {
                TouristicContents = dbContext.TouristicContents.Where(t => t.TouristicContentType == type).ToList(),
                Type = type
            };

            return(View(model));
        }
Exemple #2
0
        public ActionResult AddTouristicContent(TouristicContentType type)
        {
            var model = new TouristicContentViewModel
            {
                TouristicContent = new TouristicContent
                {
                    TouristicContentType = type
                }
            };

            return(View(model));
        }