コード例 #1
0
        [Route("[action]")] //whatever the method is called is the route
        public IActionResult GetOrders()
        {
            OrderModel      model = new OrderModel(_db);
            ApplicationUser user  = HttpContext.Session.Get <ApplicationUser>(SessionVariables.User);

            return(Ok(model.GetAllForUser(user)));
        }