示例#1
0
        public async Task <IActionResult> Get()
        {
            var levels = await _levelRepositoryAsync.GetAllAsync();

            return(Ok(levels));
        }
示例#2
0
        // public IActionResult Index()
        // {
        //     var classes = classRepositoryAsync.GetAllAsync();
        //     return View(classes);
        // }

        public async Task <IActionResult> Index()
        {
            var classes = await levelRepositoryAsync.GetAllAsync();

            return(View(classes));
        }