예제 #1
0
        protected virtual void LoadIncomes(long oidExpediente)
        {
            if (_facturas_ingresos_list != null)
            {
                return;
            }

            try
            {
                PgMng.Reset(3, 1, Face.Resources.Messages.LOADING_DATA, this);

                _facturas_ingresos_list    = OutputInvoiceList.GetByExpedienteList(oidExpediente, false);
                Datos_FIngresos.DataSource = _facturas_ingresos_list;
                PgMng.Grow();

                TotalPendienteFacturasE_NTB.Text  = _facturas_ingresos_list.TotalPendiente().ToString("N2");
                TotalFacturasE_NTB.Text           = _facturas_ingresos_list.Total().ToString("N2");
                TotalExpedienteFacturasE_NTB.Text = _facturas_ingresos_list.TotalExpediente().ToString("N2");

                BePurchases_NTB.Text = TotalExpedienteFacturasE_NTB.DecimalValue.ToString("C2");

                _conceptos_ingresos_list   = OutputInvoiceLineList.GetByExpedienteList(oidExpediente, false);
                Datos_CIngresos.DataSource = _conceptos_ingresos_list;
                PgMng.Grow();

                CalculateBeneficios();
            }
            finally
            {
                PgMng.FillUp();
            }
        }
예제 #2
0
        protected virtual void LoadIncomes(bool reload = false)
        {
            LoadIncomes(EntityInfoNoChilds.Oid);

            if (_works_output_invoices == null || reload)
            {
                try
                {
                    PgMng.Reset(3, 1, Face.Resources.Messages.LOADING_DATA, this);

                    _works_output_invoices = OutputInvoiceList.GetByExpedienteList(EntityInfo.Relations.ToChildsOidList(), false);
                    PgMng.Grow();

                    BeWorksPurchases_NTB.Text = (_works_output_invoices != null) ? _works_output_invoices.TotalExpediente().ToString("C2") : (0).ToString("C2");

                    CalculateBeneficios();
                }
                finally
                {
                    PgMng.FillUp();
                }
            }
        }