예제 #1
0
 public IEnumerable <string> Get()
 {
     try
     {
         var           acoes     = _acaoRepository.GetAll();
         List <string> acoesList = new List <string>();
         acoes.ToList().ForEach(acao =>
         {
             acoesList.Add(acao.NmAcao);
         });
         return(acoesList);
     }
     catch (Exception ex)
     {
         return(new string[] { "ERRO: " + ex.Message });
     }
     //return new string[] { "value1", "value2" };
 }
예제 #2
0
        public IActionResult List()
        {
            var lstAcoes = _acaoRepository.GetAll();

            return(View(lstAcoes));
        }