private void PreencherTotal2012()
        {
            DRES dres = new DRES();
            var total = dres.Todos();

            PreencherLiteral(false, false, ltlReceitaBrutaTotal2012, total.Sum(t => t.TotalReceitaBruta));
            PreencherLiteral(true, false, ltlDeducoesTotal2012, total.Sum(t => t.TotalDeducoes));
            PreencherLiteral(true, false, ltlGlosaInternaTotal2012, total.Sum(t => t.TotalGlosaInterna));
            PreencherLiteral(false, true, ltlGlosaInternaRBTotal2012, total.Sum(t => t.TotalPercentualGlosaInterna));
            PreencherLiteral(true, false, ltlGlosaExternaTotal2012, total.Sum(t => t.TotalGlosaExterna));
            PreencherLiteral(false, true, ltlGlosaExternaRBTotal2012, total.Sum(t => t.TotalPercentualGlosaExterna));
            PreencherLiteral(true, false, ltlImpostosTotal2012, total.Sum(t => t.TotalImpostos));
            PreencherLiteral(false, true, ltlImpostosRBTotal2012, total.Sum(t => t.TotalPercentualImpostos));
            PreencherLiteral(false, false, ltlReceitaLiquidaTotal2012, total.Sum(t => t.TotalReceitaLiquida));
            PreencherLiteral(true, false, ltlDespesasOperacionaisTotal2012, total.Sum(t => t.TotalDespesasOperacionais));
            PreencherLiteral(true, false, ltlPessoalTotal2012, total.Sum(t => t.TotalPessoal));
            PreencherLiteral(true, false, ltlServicosMedicosTotal2012, total.Sum(t => t.TotalServicosMedicos));
            PreencherLiteral(true, false, ltlInsumosTotal2012, total.Sum(t => t.TotalInsumos));
            PreencherLiteral(false, true, ltlInsumosRLTotal2012, total.Sum(t => t.TotalPercentualInsumos));
            PreencherLiteral(true, false, ltlServicosContratadosTotal2012, total.Sum(t => t.TotalServicosContratados));
            PreencherLiteral(true, false, ltlOcupacaoTotal2012, total.Sum(t => t.TotalOcupacao));
            PreencherLiteral(true, false, ltlUtilidadesEServicosTotal2012, total.Sum(t => t.TotalUtilidadeServico));
            PreencherLiteral(true, false, ltlDespesasGeraisTotal2012, total.Sum(t => t.TotalDespesasGerais));
            PreencherLiteral(true, false, ltlMarketingTotal2012, total.Sum(t => t.TotalMarketing));
            PreencherLiteral(false, false, ltlDescontosObtidosTotal2012, total.Sum(t => t.TotalDescontosObtidos));
            PreencherLiteral(false, false, ltlMargemBrutaTotal2012, total.Sum(t => t.TotalMargemBruta));
            PreencherLiteral(false, true, ltlMargemBrutaPorcentagemTotal2012, total.Sum(t => t.TotalPercentualMargemBruta));
        }
예제 #2
0
        public void Deletar_DRE_TOtal()
        {
            DRES dres = new DRES();
            var todos = dres.Todos<DRETotal>();

            var filtrados = todos.Where(t => t.Departamento.Tipo == TipoDepartamento.setor).ToList();

            dres.Deletar(filtrados);
        }