Esempio n. 1
0
        public static ActionResult Ok <T>(T data)
            where T : class, new()
        {
            var returnBody = new ReturnBody <T>(data);

            return(new OkObjectResult(returnBody));
        }
Esempio n. 2
0
        public static ActionResult Error(string message)
        {
            var returnBody = new ReturnBody(-1, message);

            return(new OkObjectResult(returnBody));
        }
Esempio n. 3
0
        public static IActionResult Ok()
        {
            var returnBody = new ReturnBody();

            return(new OkObjectResult(returnBody));
        }