public IViewComponentResult Invoke() { EstatisticasDespesasViewModel estatisticas = new EstatisticasDespesasViewModel(); estatisticas = _despesaAppService.RetornarDadosEstatisticasDespesas(); return(View(estatisticas)); }
public EstatisticasDespesasViewModel RetornarDadosEstatisticasDespesas() { var estatisticasDespesasEntidade = _despesaRepository.RetornarDadosEstatisticasDespesas(); if (estatisticasDespesasEntidade != null) { var estatisticasDespesasViewModel = new EstatisticasDespesasViewModel { MenorDespesa = estatisticasDespesasEntidade.MenorDespesa, MaiorDespesa = estatisticasDespesasEntidade.MaiorDespesa, QuantidadeDespesas = estatisticasDespesasEntidade.QuantidadeDespesas }; return(estatisticasDespesasViewModel); } return(null); }