Exemplo n.º 1
0
 public static ModeloList GetList(QueryConditions conditions, bool childs)
 {
     return(GetList(SELECT(conditions), childs));
 }
 public static string SELECT(QueryConditions conditions)
 {
     return(InterestRate.SELECT(conditions, true));
 }
Exemplo n.º 3
0
 public static string SELECT(QueryConditions conditions)
 {
     return(Traspaso.SELECT(conditions, true));
 }
        private void GetFacturas(ClienteInfo cliente,
                                 QueryConditions conditions,
                                 FormatConfCarteraClientesReport conf,
                                 List <CarteraClientesPrint> pList,
                                 List <CobroFacturaPrint> pCobroList)
        {
            OutputInvoiceList facturas;

            conditions.Cliente = cliente;

            switch (conf.tipo)
            {
            case ETipoFacturas.Cobradas:
            {
                facturas = OutputInvoiceList.GetCobradasList(conditions, false);

                if (facturas.Count > 0)
                {
                    foreach (OutputInvoiceInfo f in facturas)
                    {
                        f.LoadChilds(typeof(CobroFacturaInfo), false);

                        pList.Add(cliente.GetCarteraPrintObject(f));

                        foreach (CobroFacturaInfo cobro in f.CobroFacturas)
                        {
                            pCobroList.Add(CobroFacturaPrint.New(cobro));
                        }
                    }
                }
            } break;

            case ETipoFacturas.Pendientes:
            {
                facturas = OutputInvoiceList.GetNoCobradasList(conditions, false);

                if (facturas.Count > 0)
                {
                    foreach (OutputInvoiceInfo f in facturas)
                    {
                        f.LoadChilds(typeof(CobroFacturaInfo), false);

                        pList.Add(cliente.GetCarteraPrintObject(f));

                        foreach (CobroFacturaInfo cobro in f.CobroFacturas)
                        {
                            pCobroList.Add(CobroFacturaPrint.New(cobro));
                        }
                    }
                }
            }
            break;

            case ETipoFacturas.Todas:
            {
                facturas = OutputInvoiceList.GetList(conditions, false);

                if (facturas.Count == 0)
                {
                    pList.Add(cliente.GetCarteraPrintObject(null));
                }
                else
                {
                    foreach (OutputInvoiceInfo f in facturas)
                    {
                        f.LoadChilds(typeof(CobroFacturaInfo), false);

                        if (f.CobroFacturas.Count > 0)
                        {
                            pList.Add(cliente.GetCarteraPrintObject(f));

                            foreach (CobroFacturaInfo cobro in f.CobroFacturas)
                            {
                                pCobroList.Add(CobroFacturaPrint.New(cobro));
                            }
                        }
                        else
                        {
                            pList.Add(cliente.GetCarteraPrintObject(f));
                        }
                    }
                }
            }
            break;
            }
        }
Exemplo n.º 5
0
 public static string SELECT(QueryConditions conditions)
 {
     return(AlbaranTicket.SELECT(conditions, true));
 }
 public static Transactiones GetList(QueryConditions conditions, bool childs)
 {
     return(GetList(Transactiones.SELECT(conditions), childs));
 }
 public static OutputInvoiceLineList GetList(QueryConditions conditions, bool childs)
 {
     return(GetList(OutputInvoiceLineList.SELECT(conditions), childs));
 }
Exemplo n.º 8
0
 public static OutputInvoiceList GetDudosoCobroList(QueryConditions conditions, bool childs)
 {
     conditions.TipoFacturas = ETipoFacturas.DudosoCobro;
     return(GetList(conditions, childs));
 }
Exemplo n.º 9
0
 public static OutputInvoiceList GetBeneficioList(QueryConditions conditions, bool childs)
 {
     return(GetList(OutputInvoice.SELECT_BENEFICIO(conditions, false), childs));
 }
Exemplo n.º 10
0
 public static OutputInvoiceList GetCobradasList(QueryConditions conditions, bool childs)
 {
     conditions.TipoFacturas = ETipoFacturas.Cobradas;
     return(GetList(OutputInvoiceList.SELECT(conditions), false));
 }
Exemplo n.º 11
0
 public static OutputInvoiceList GetNoCobradasList(QueryConditions conditions, bool childs)
 {
     conditions.TipoFacturas = ETipoFacturas.Pendientes;
     return(GetList(conditions, childs));
 }
Exemplo n.º 12
0
 public static string SELECT(QueryConditions conditions)
 {
     return(BankLine.SELECT(conditions, true));
 }
Exemplo n.º 13
0
 public static string SELECT(QueryConditions conditions)
 {
     return(FinancialCash.SELECT(conditions, true));
 }
Exemplo n.º 14
0
 public static string SELECT(QueryConditions conditions)
 {
     return(ModeloInfo.SELECT(conditions));
 }
Exemplo n.º 15
0
 public static Charges GetList(QueryConditions conditions, bool childs)
 {
     conditions.Order = System.ComponentModel.ListSortDirection.Descending;
     return(GetList(childs, Charges.SELECT(conditions)));
 }
Exemplo n.º 16
0
 public static string SELECT(QueryConditions conditions)
 {
     return(OutputInvoice.SELECT(conditions, false));
 }
Exemplo n.º 17
0
 public static string SELECT(QueryConditions conditions)
 {
     return(Invoice.Transaction.SELECT(conditions, true));
 }
Exemplo n.º 18
0
 public static CashLineList GetList(QueryConditions conditions, bool childs)
 {
     return(GetList(CashLineList.SELECT(conditions), childs));
 }
Exemplo n.º 19
0
 public static string SELECT(QueryConditions conditions)
 {
     return(OutputDelivery.SELECT(conditions, false));
 }
Exemplo n.º 20
0
 public static string SELECT(QueryConditions conditions)
 {
     return(CashLine.SELECT(conditions, false));
 }
Exemplo n.º 21
0
        internal static string WHERE(QueryConditions conditions)
        {
            string query;

            query = " WHERE (F.\"FECHA\" BETWEEN '" + conditions.FechaIniLabel + "' AND '" + conditions.FechaFinLabel + "')";

            switch (conditions.Estado)
            {
            case EEstado.Todos:
                break;

            case EEstado.NoAnulado:
                query += " AND C.\"ESTADO\" != " + (long)EEstado.Anulado;
                break;

            default:
                query += " AND C.\"ESTADO\" = " + (long)conditions.Estado;
                break;
            }

            if (conditions.Cliente != null)
            {
                query += " AND F.\"OID_CLIENTE\" = " + conditions.Cliente.Oid;
            }

            if (conditions.Cobro != null)
            {
                query += " AND CF.\"OID_COBRO\" = " + conditions.Cobro.Oid;
            }

            if (conditions.Serie != null)
            {
                query += " AND F.\"OID_SERIE\" = " + conditions.Serie.Oid;
            }

            if (conditions.Factura != null)
            {
                query += " AND CF.\"OID_FACTURA\" = " + conditions.Factura.Oid;
            }

            switch (conditions.MedioPago)
            {
            case EMedioPago.NoEfectivo:
                query += " AND C.\"MEDIO_PAGO\" != " + (long)EMedioPago.Efectivo;
                break;

            default:
                if (conditions.MedioPago != EMedioPago.Todos)
                {
                    query += " AND C.\"MEDIO_PAGO\" = " + (long)conditions.MedioPago;
                }
                break;
            }

            if (conditions.MedioPagoList != null && conditions.MedioPagoList.Count > 0)
            {
                query += EntityBase.GET_IN_LIST_CONDITION(conditions.MedioPagoList, "C", "MEDIO_PAGO");
            }

            return(query);
        }
Exemplo n.º 22
0
 public static string SELECT(QueryConditions conditions)
 {
     return(ChargeSummary.SELECT(conditions));
 }
 public static string SELECT_PENDIENTES(QueryConditions conditions)
 {
     return(LineaPedido.SELECT_PENDIENTES(conditions, false));
 }
Exemplo n.º 24
0
 public static string SELECT_PENDIENTES(QueryConditions conditions)
 {
     return(ChargeSummary.SELECT_PENDIENTES(conditions));
 }
Exemplo n.º 25
0
 public static string SELECT(QueryConditions conditions)
 {
     return(Cliente.SELECT(Cliente.EQueryType.GENERAL, conditions, false));
 }
Exemplo n.º 26
0
 public static string SELECT_DUDOSO_COBRO(QueryConditions conditions)
 {
     return(ChargeSummary.SELECT_DUDOSO_COBRO(conditions));
 }
Exemplo n.º 27
0
 public static Traspasos GetList(QueryConditions conditions, bool childs)
 {
     return(GetList(childs, Traspasos.SELECT(conditions)));
 }
Exemplo n.º 28
0
 public static ChargeList GetListByVencimientoSinApunte(QueryConditions conditions, bool childs)
 {
     return(GetList(Charge.SELECT_VENCIMIENTO_SIN_APUNTE(conditions), childs));
 }
Exemplo n.º 29
0
 public static string SELECT(QueryConditions conditions)
 {
     return(CobroFactura.SELECT(conditions, true));
 }
Exemplo n.º 30
0
 internal static string SELECT(QueryConditions conditions, bool lock_table)
 {
     return(SELECT(0, conditions, lock_table));
 }