Ejemplo n.º 1
0
 public IActionResult Get()
 {
     _logger.Write("EstadosController:Get");
     _context = new Core.ContextWrapper(HttpContext);
     return(new JsonResult(new string[] { "Pendiente",
                                          "Cerrado",
                                          _context.GetItem("33") }));
 }
Ejemplo n.º 2
0
        public IActionResult GetTraceLines()
        {
            _context = new Core.ContextWrapper(HttpContext);

            Response.ContentType = "text/html";
            StringBuilder _sb = new StringBuilder();

            _sb.AppendLine("<h2>Trace</h2>");
            _sb.AppendLine("<pre>");
            foreach (string line in _logger.GetLines())
            {
                _sb.AppendLine(line);
            }
            _sb.AppendLine("</pre>");
            return(Content(_sb.ToString()));

            //return new JsonResult( _logger.GetLines().ToArray<string>());
        }