コード例 #1
0
        public JsonResult GetSelectListNetworks()
        {
            if (!WebSecurity.IsAuthenticated)
            {
                return(null);
            }
            var list = reposetory.GetAllNetworks().Where(n => n.NetworkNotToShow != true).OrderBy(a => a.NetworkName);

            return(Json(new SelectList(list.ToArray(), "NetworkID", "NetworkName"), JsonRequestBehavior.AllowGet));
        }
コード例 #2
0
        public ActionResult Index()
        {
            List <Network> networks = reposetory.GetAllNetworks();

            return(View(networks));
        }