예제 #1
0
        public JsonResult ListJson()
        {
            SchoolsServices mongo   = new SchoolsServices("school", "school", "mongodb://localhost:27017/");
            var             schools = mongo.getAll();

            return(Json(schools));
        }
예제 #2
0
        public IActionResult List()
        {
            SchoolsServices mongo   = new SchoolsServices("school", "school", "mongodb://localhost:27017/");
            var             schools = mongo.getAll();

            return(View("List", schools));
        }