Пример #1
0
        public ActionResult RadarElementAdd()
        {
            var radarcategorylist = RadarService.GetRadarCategoryList().ToList();

            ViewData["RadarCategorylist"] = radarcategorylist.GetSelectList();
            return(View());
        }
Пример #2
0
        public ActionResult RadarElementEdit(int radarElementId)
        {
            var allradarcategorylist = RadarService.GetRadarCategoryList().ToList();
            var radarelement         = dbContextService.Single <RadarElement>(radarElementId);

            var radarelementview = radarelement.To <RadarElementView>();

            ViewData["RadarCategorylist"] = allradarcategorylist.GetSelectList();
            ViewData["RadarCategoryIds"]  = radarelementview.RadarCategoryIds;
            ViewData["IsUpdate"]          = true;
            return(View("RadarElementAdd", radarelementview));
        }