Example #1
0
        public ActionResult InfAddressAdd()
        {
            var sourcelist      = NewsUIService.GetNewsSourceList().ToList();
            var categorylist    = NewsUIService.GetNewsCategoryList().ToList();
            var subcategorylist = NewsUIService.GetNewsSubCategoryList().ToList();

            ViewData["Sourcelist"]      = sourcelist.GetSelectList();
            ViewData["Categorylist"]    = categorylist.GetSelectList();
            ViewData["SubCategorylist"] = subcategorylist.GetSelectList();
            return(View());
        }
Example #2
0
        public ActionResult NewsAdd()
        {
            var categorylist    = NewsUIService.GetNewsCategoryList().ToList();
            var subcategorylist = NewsUIService.GetNewsSubCategoryList().ToList();
            var extraapplist    = NewsUIService.GetNewsExtraAppList().ToList();

            ViewData["Categorylist"]    = categorylist.GetSelectList();
            ViewData["SubCategorylist"] = subcategorylist.GetSelectList();
            ViewData["ExtraApplist"]    = extraapplist.GetSelectList();

            return(View());
        }
Example #3
0
        public ActionResult InfAddressEdit(int infAddressId)
        {
            var extraApp = dbContextService.Single <NewsInfAddress>(infAddressId);

            var sourcelist      = NewsUIService.GetNewsSourceList().ToList();
            var categorylist    = NewsUIService.GetNewsCategoryList().ToList();
            var subcategorylist = NewsUIService.GetNewsSubCategoryList().ToList();

            ViewData["Sourcelist"]      = sourcelist.GetSelectList();
            ViewData["Categorylist"]    = categorylist.GetSelectList();
            ViewData["SubCategorylist"] = subcategorylist.GetSelectList();

            ViewData["IsUpdate"] = true;
            return(View("InfAddressAdd", extraApp));
        }
Example #4
0
        public ActionResult NewsEdit(int newsId)
        {
            var news = dbContextService.Single <NewsContent>(newsId);

            var categorylist    = NewsUIService.GetNewsCategoryList().ToList();
            var subcategorylist = NewsUIService.GetNewsSubCategoryList().ToList();
            var extraapplist    = NewsUIService.GetNewsExtraAppList().ToList();

            ViewData["Categorylist"]    = categorylist.GetSelectList(news.CategoryId);
            ViewData["SubCategorylist"] = subcategorylist.GetSelectList(news.SubCategoryId);
            ViewData["ExtraApplist"]    = extraapplist.GetSelectList(news.ExtraAppId);

            ViewData["IsUpdate"] = true;
            return(View("NewsAdd", news));
        }