コード例 #1
0
        public JsonResult Consultar()
        {
            var servicos = _servicoRepositorio
                           .ObterServicos()
                           .Select(c => new
            {
                Id                 = c.Id,
                Descricao          = c.Descricao,
                Status             = c.Status,
                RecintoAlfandegado = c.RecintoAlfandegado,
                Operador           = c.Operador,
                Redex              = c.Redex
            });

            return(Json(new
            {
                dados = servicos
            }, JsonRequestBehavior.AllowGet));
        }