示例#1
0
        public static ActionResult Ok <T>(T data)
            where T : class, new()
        {
            var returnBody = new ReturnBody <T>(data);

            return(new OkObjectResult(returnBody));
        }
示例#2
0
        public static ActionResult Error(string message)
        {
            var returnBody = new ReturnBody(-1, message);

            return(new OkObjectResult(returnBody));
        }
示例#3
0
        public static IActionResult Ok()
        {
            var returnBody = new ReturnBody();

            return(new OkObjectResult(returnBody));
        }