Esempio n. 1
0
        //German 20120208 - Tarea 0000276
        public string GetLayoutBuscadorProductos()
        {
            ArrayList fl = new ArrayList();
            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int i = 0;
            StringBuilder sb = new StringBuilder();
            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdBonificacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "IdBonificacion", "IdBonificacion", true));
            if (fl.Contains("Ordinal") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "Ordinal", "Ordinal", true));
            if (fl.Contains("Minimo") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "Minimo", "Cant. Min", 75, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("Maximo") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "Maximo", "Cant. Max", 75, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("Valor") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "Valor", "% Bonif.", 75, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("PrecioFinal") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "PrecioFinal", "Precio", 125, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("MontoBonificacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "MontoBonificacion", "Bonificación", 125, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("PrecioFinalBonificacionesAplicadas") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "PrecioFinalBonificacionesAplicadas", "Precio Con Bonif.", 150, Types.Aligment.Far, Types.FormatDisplay.Money));
            if (fl.Contains("FechaCreacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "FechaCreacion", "FechaCreacion", true));
            if (fl.Contains("IdConexionCreacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "IdConexionCreacion", "IdConexionCreacion", true));
            if (fl.Contains("UltimaModificacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "UltimaModificacion", "UltimaModificacion", true));
            if (fl.Contains("IdConexionUltimaModificacion") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "IdConexionUltimaModificacion", "IdCoexionUltimaModificacion", true));
            if (fl.Contains("IdReservado") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "IdReservado", "IdReservado", true));
            if (fl.Contains("RowId") || _fieldList == null) sb.Append(LayoutBuilder.GetRow(i++, "RowId", "RowId", true));

            sb.Append(LayoutBuilder.GetFooter());

            return sb.ToString();

        }
Esempio n. 2
0
        public static string GetLayoutErrores(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }
            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Tabla") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Tabla", "Tabla", 150));
            }
            if (fl.Contains("Campo") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Campo", "Campo", 150));
            }
            if (fl.Contains("Mensaje") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRowWordWrap(i++, "Mensaje", "Mensaje", 300, 5));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 3
0
		public string GetLayout()
		{
			ArrayList fl = new ArrayList();
			if ( _fieldList != null )
			{
				fl.AddRange( _fieldList );
			}

			int i = 0;
			StringBuilder sb = new StringBuilder();
			sb.Append( LayoutBuilder.GetHeader() );
			
			if ( fl.Contains( "IdBonificacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdBonificacion", "IdBonificacion" ,true) );
			if ( fl.Contains( "Ordinal" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "Ordinal", "Ordinal",true ) );
			if ( fl.Contains( "Minimo" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "Minimo", "Minimo" ) );
			if ( fl.Contains( "Maximo" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "Maximo", "Maximo" ) );
			if ( fl.Contains( "Valor" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "Valor", "Valor" ) );
			if ( fl.Contains( "FechaCreacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "FechaCreacion", "FechaCreacion" ,true) );
			if ( fl.Contains( "IdConexionCreacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdConexionCreacion", "IdConexionCreacion",true ) );
			if ( fl.Contains( "UltimaModificacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "UltimaModificacion", "UltimaModificacion",true ) );
			if ( fl.Contains( "IdConexionUltimaModificacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdConexionUltimaModificacion", "IdCoexionUltimaModificacion",true ) );
			if ( fl.Contains( "IdReservado" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdReservado", "IdReservado", true ) );
			if ( fl.Contains( "RowId" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "RowId", "RowId", true ) );
			
			sb.Append( LayoutBuilder.GetFooter() );

			return sb.ToString();

		}
Esempio n. 4
0
        public static string GetLayoutImpuestos(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            Types.Aligment ali;

            if (fl.Contains("Nombre") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Nombre", "Nombre", 170));
            }
            if (fl.Contains("DescripcionCorta") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "DescripcionCorta", "Impuesto", 170));
            }
            if (fl.Contains("Valor") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Valor", "Valor", 80, Types.Aligment.Far, Types.FormatDisplay.Money));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 5
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdVariableAuxiliarTDCompTesoreria") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdVariableAuxiliarTDCompTesoreria", "IdVariableAuxiliarTDCompTesoreria", true));
            }
            if (fl.Contains("DescripcionComprobante") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "DescripcionComprobante", "Comprobante", true));
            }
            if (fl.Contains("DescripcionVariable") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "DescripcionVariable", "Descripcion Variable", 250));
            }
            if (fl.Contains("Valor") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Valor", "Valor", 250));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 6
0
        public static string GetLayoutDetalleCondicionDeVenta(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdCuota") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdCuota", "Cuota", 30));
            }
            if (fl.Contains("FechaVencimiento") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaVencimiento", "Vence", 90));
            }
            if (fl.Contains("Monto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Monto", "Monto", 60));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 7
0
        public string GetLayoutDetalleValores()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Comprobante") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Comprobante", "Comprobante", 100));
            }
            if (fl.Contains("Moneda") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Moneda", "Moneda", 75));
            }
            if (fl.Contains("Monto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Monto", "Monto Moneda Origen", 100, Types.Aligment.Far, Types.FormatDisplay.Money));
            }
            if (fl.Contains("MontoCotizado") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "MontoCotizado", "Monto Cotizado", 100, Types.Aligment.Far, Types.FormatDisplay.Money));
            }
            if (fl.Contains("ValorCotizacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "ValorCotizacion", "Valor de Cotizacion", 100, Types.Aligment.Far, Types.FormatDisplay.Money));
            }
            if (fl.Contains("Fecha") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Fecha", "Fecha", 150));
            }
            if (fl.Contains("FechaVencimiento") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaVencimiento", "FechaVencimiento", 150));
            }
            if (fl.Contains("Numero") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Numero", "Numero", 75));
            }
            if (fl.Contains("Entidad") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Entidad", "Entidad", 75));
            }
            if (fl.Contains("IdCotizacionMoneda") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdCotizacionMoneda", "IdCotizacionMoneda", true));
            }


            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 8
0
        public static string GetLayoutStockSucursales(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }
            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Sucursal", 100));
            }
            if (fl.Contains("DescripcionDeposito") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "DescripcionDeposito", "Depósito", 100));
            }
            if (fl.Contains("DescripcionSeccion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "DescripcionSeccion", "Sección", 100));
            }
            if (fl.Contains("Suma") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Suma", "Cantidad", 60, Types.Aligment.Far, Types.FormatDisplay.Integer));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 9
0
        public static string GetLayoutVariables(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }
            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Id") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Id", "Id", true));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripcion", 100));
            }
            if (fl.Contains("Valor") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRowWordWrap(i++, "Valor", "Valor", 400, 20));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 10
0
    private static MailLayout ReplaceTemplatePlaceholder(OrderInfo orderDetails, string numOrdine, string fileName,
                                                         string orderItem)
    {
        // Refactoring futuro: builder per costruire un oggetto Order con i campi seguenti
        // Reflection sulle proprietà dell'oggetto, cercando il placeholder relativo nel template e sostituendo con il
        // valore del campo
        var name           = string.Format("{0} {1}", orderDetails.billing_address.firstname, orderDetails.billing_address.lastname);
        var shipmentHolder = string.Format("{0} {1}", orderDetails.shipping_address.firstname,
                                           orderDetails.shipping_address.lastname);
        var shipmentAddress = string.Format("{0} {1} {2}", orderDetails.shipping_address.street,
                                            orderDetails.shipping_address.city, orderDetails.shipping_address.postcode);
        var invoiceHolder = string.Format("{0} {1}", orderDetails.billing_address.firstname,
                                          orderDetails.billing_address.lastname);
        var invoiceAddress = string.Format("{0} {1}", orderDetails.billing_address.firstname,
                                           orderDetails.billing_address.lastname);
        var totalShipment = "€. " + Helper.FormatCurrency(orderDetails.shipping_amount);
        var total         = Helper.FormatCurrency(orderDetails.grand_total);

        var layoutBuilder = new LayoutBuilder(fileName);
        var templateHtml  = layoutBuilder.AddName(name)
                            .AddInvoiceHolder(invoiceHolder).AddInvoiceAddress(invoiceAddress)
                            .AddShipmentHolder(shipmentHolder).AddShipmentAddress(shipmentAddress)
                            .AddOrderItem(orderItem).AddOrderNumber(numOrdine)
                            .AddTotalShipment(totalShipment).AddTotalOrder(total).Build();

        return(templateHtml);
    }
Esempio n. 11
0
        private static void ProcessText(XDocument xdoc)
        {
            System.Collections.Generic.IEnumerable <XElement> attributesToDelete = from ele in xdoc.Descendants()
                                                                                   where ele != null && ele.Attribute("Text") != null
                                                                                   select ele;

            try
            {
                foreach (XAttribute attribute in attributesToDelete.Attributes())
                {
                    XElement parent = attribute.Parent;

                    System.Collections.Generic.IEnumerable <XElement> toDelete = from ele in xdoc.Descendants()
                                                                                 where ele != null && ele.Attribute("Text") != null
                                                                                 select ele;

                    foreach (XAttribute att in toDelete.Attributes())
                    {
                        att.Remove();
                    }

                    parent.SetAttributeValue("TextColor", $"#{LayoutBuilder.GetColor(true).ToHex()}");
                    parent.SetAttributeValue("Text", TextBuilder.GenerateLoremText(attribute.Value));
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex);
            }
        }
        public static string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());


            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Comprobante", 100));
            }
            if (fl.Contains("Numero") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Numero", "Numero", 125));
            }
            if (fl.Contains("Fecha") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Fecha", "Fecha", 125));
            }

            if (fl.Contains("Cantidad") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Cantidad", "Cant.", 50));
            }
            if (fl.Contains("CodigoProducto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "CodigoProducto", "Cod. Prod", 50));
            }
            if (fl.Contains("Producto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Producto", "Producto", 200));
            }


            if (fl.Contains("Codigo") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Codigo", "Codigo", true));
            }
            if (fl.Contains("Nombre") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Nombre", "Cliente", 200));
            }
            if (fl.Contains("Total") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Total", "Total", 100, Types.Aligment.Far, Types.FormatDisplay.Money));
            }


            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
        public static string GetLayoutAbmCuentasCondicionesDeVenta()
        {
            string[]  _fieldList = new string[] { "Descripcion", "Valor" };
            ArrayList fl         = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            //if ( fl.Contains( "IdCuenta" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdCuenta", "IdCuenta" , true));
            //if ( fl.Contains( "IdCondicionDeVenta" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdCondicionDeVenta", "IdCondicionDeVenta", false) );
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripción", 250, Types.ColumnTypes.Text, Types.EditType.NoEdit));
            }
            if (fl.Contains("Valor") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Valor", "Valor", 50, Types.ColumnTypes.CheckBox, Types.EditType.CheckBox));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 14
0
 public XVGMLService()
 {
     builder = new LayoutBuilder();
     builder.RegisterPackage(new XVGML.Basic.PackageDescriptor());
     builder.RegisterPackage(new XVGML.Web.PackageDescriptor());
     renderer = new LayoutRenderer();
 }
Esempio n. 15
0
        public static string GetLayoutAjusteDeStock()
        {
            string[] _fieldList = new string[] { "Codigo", "Descripcion", "Cantidad" };

            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }
            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Codigo") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Codigo", "Código", 100, Types.EditType.NoEdit));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripción", 500, Types.EditType.NoEdit));
            }
            if (fl.Contains("Cantidad") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Cantidad", "Cantidad", 60, Types.Aligment.Far, Types.FormatDisplay.Integer, Types.EditType.Custom));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 16
0
        public string GetLayoutBonif()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdBonificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdBonificacion", "Id", 50, false));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripción", 200, false));
            }
            if (fl.Contains("IdTipoBonificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdTipoBonificacion", "Tipo de bonificación", 50, false));
            }
            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
        public string  GetLayoutComprobantesTesoreria()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdTDCompTesoreria") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdTDCompTesoreria", "IdTDCompTesoreria", true));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripcion", 200));
            }
            if (fl.Contains("Agrupado") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Agrupado", "Agrupado", true));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 18
0
        public static string GetLayoutResumenImpuestos(string[] _fieldList)
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("Impuesto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Impuesto", "Impuesto", 200));
            }
            if (fl.Contains("Valor") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Valor", "Valor", 70, Types.Aligment.Near, Types.FormatDisplay.Percent));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 19
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdSubTipoMovimiento") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdSubTipoMovimiento", "IdSubTipoMovimiento"));
            }
            if (fl.Contains("IdTipoMovimiento") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdTipoMovimiento", "IdTipoMovimiento"));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripcion"));
            }
            if (fl.Contains("Sistema") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Sistema", "Sistema"));
            }
            if (fl.Contains("FechaCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaCreacion", "FechaCreacion"));
            }
            if (fl.Contains("IdConexionCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionCreacion", "IdConexionCreacion"));
            }
            if (fl.Contains("UltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "UltimaModificacion", "UltimaModificacion"));
            }
            if (fl.Contains("IdConexionUltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionUltimaModificacion", "IdConexionUltimaModificacion"));
            }
            if (fl.Contains("IdReservado") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdReservado", "IdReservado"));
            }
            if (fl.Contains("RowId") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "RowId", "RowId"));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 20
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdPerfil") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdPerfil", "IdPerfil"));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripcion"));
            }
            if (fl.Contains("Activo") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Activo", "Activo"));
            }
            if (fl.Contains("Comentario") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Comentario", "Comentario"));
            }
            if (fl.Contains("IdConexion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexion", "IdConexion"));
            }
            if (fl.Contains("FechaCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaCreacion", "FechaCreacion"));
            }
            if (fl.Contains("IdConexionCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionCreacion", "IdConexionCreacion"));
            }
            if (fl.Contains("UltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "UltimaModificacion", "UltimaModificacion"));
            }
            if (fl.Contains("IdConexionUltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionUltimaModificacion", "IdConexionUltimaModificacion"));
            }
            if (fl.Contains("RowId") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "RowId", "RowId"));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 21
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdTratamiento") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdTratamiento", "IdTratamiento", true));
            }
            if (fl.Contains("Abreviatura") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Abreviatura", "Abreviatura", 250, Types.Aligment.Center, Types.FormatDisplay.Default));
            }
            if (fl.Contains("Texto") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Texto", "Texto", 250, Types.Aligment.Center, Types.FormatDisplay.Default));
            }
            if (fl.Contains("FechaCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaCreacion", "FechaCreacion", true));
            }
            if (fl.Contains("IdConexionCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionCreacion", "IdConexionCreacion", true));
            }
            if (fl.Contains("UltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "UltimaModificacion", "UltimaModificacion", true));
            }
            if (fl.Contains("IdConexionUltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionUltimaModificacion", "IdConexionUltimaModificacion", true));
            }
            if (fl.Contains("IdReservado") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdReservado", "IdReservado", true));
            }
            if (fl.Contains("RowId") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "RowId", "RowId", true));
            }
            if (fl.Contains("IdEmpresa") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdEmpresa", "IdEmpresa", true));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 22
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdCaja") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdCaja", "Caja", 250));
            }
            if (fl.Contains("IdResponsable") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdResponsable", "Responsable", 250));
            }
            if (fl.Contains("FechaCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "FechaCreacion", "FechaCreacion", true));
            }
            if (fl.Contains("IdConexionCreacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionCreacion", "IdConexionCreacion", true));
            }
            if (fl.Contains("UltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "UltimaModificacion", "UltimaModificacion", true));
            }
            if (fl.Contains("IdConexionUltimaModificacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdConexionUltimaModificacion", "IdConexionUltimaModificacion", true));
            }
            if (fl.Contains("IdReservado") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdReservado", "IdReservado", true));
            }
            if (fl.Contains("RowId") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "RowId", "RowId,", true));
            }
            if (fl.Contains("IdEmpresa") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdEmpresa", "IdEmpresa", true));
            }
            if (fl.Contains("IdSucursal") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdSucursal", "IdSucursal", true));
            }

            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }
Esempio n. 23
0
        public static Layout BuildLayout()
        {
            var b = new LayoutBuilder <Person>();

            return(new Layout
            {
            });
        }
Esempio n. 24
0
        protected override void OnLayout(LayoutBuilder layout)
        {
            var todo = layout.View(TodoList)
                       .Left(0).Right(0).Top(20).Bottom(150);

            layout.View(LoadButton)
            .Left(10).Right(10).Below(todo.LayoutBounds, 5).Bottom(5);
        }
Esempio n. 25
0
 /// <summary>
 /// Calls the layout builder plug-in to return a fluent interface for configuring a layout.
 /// You can pass a layout instance or allow the builder to build one from scratch
 /// </summary>
 /// <param name="layoutInstance">Optional instance to configure</param>
 /// <param name="declaringType">Used to configure the instance from custom attributes</param>
 /// <returns></returns>
 public ILayoutDefinition BuildUpLayout(object layoutInstance, Type declaringType, IPackage package)
 {
     if (LayoutBuilder == null)
     {
         throw new FluentBuilderException("There is no build engine installed that knows how to build layouts");
     }
     return(LayoutBuilder.BuildUpLayout(layoutInstance, declaringType, package ?? _packageContext));
 }
        public LinearLayoutBuilderTest()
        {
            builder = new LayoutBuilder(new RectangleF(0, 0, 100, 100));

            view1 = new PlatformView(0, 0, 20, 30);
            view2 = new PlatformView(0, 0, 20, 20);
            view3 = new PlatformView(0, 0, 100, 100);
        }
Esempio n. 27
0
        protected override void OnLayout(LayoutBuilder layout)
        {
            var icon = layout.View(Icon)
                       .AutoSize().Left(15).CenterVertically(VerticalAdjustment);

            layout.View(Title)
            .After(icon.LayoutBounds, IconSpacing).Right(16).CenterVertically(VerticalAdjustment).AutoHeight();
        }
Esempio n. 28
0
        public static void LayoutLabeledField(this ILabeledField field, LayoutBuilder layout)
        {
            var label = layout.View(field.Label)
                        .Left(20).AutoHeight().Width(Pixel.Val(field.LabelWidth)).CenterVertically();

            layout.View(field.Text)
            .After(label.LayoutBounds, 9.5f).AutoHeight().Right(0).CenterVertically();
        }
Esempio n. 29
0
        protected override void OnLayout(LayoutBuilder layout)
        {
            var title = layout.View(Title)
                        .Top(TopInset).Left(0).Right(0).Height(44);

            layout.View(Form)
            .Below(title.LayoutBounds).Left(0).Right(0).Bottom(0);
        }
Esempio n. 30
0
        public string GetLayout()
        {
            ArrayList fl = new ArrayList();

            if (_fieldList != null)
            {
                fl.AddRange(_fieldList);
            }

            int           i  = 0;
            StringBuilder sb = new StringBuilder();

            sb.Append(LayoutBuilder.GetHeader());

            if (fl.Contains("IdDeposito") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdDeposito", "IdDeposito", 150));
            }
            if (fl.Contains("IdSeccion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdSeccion", "IdSeccion", 150));
            }
            if (fl.Contains("Descripcion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Descripcion", "Descripcion", 250));
            }
            if (fl.Contains("Ubicacion") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Ubicacion", "Ubicacion", 150));
            }
            if (fl.Contains("Comentario") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Comentario", "Comentario", 200));
            }
            if (fl.Contains("Activo") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "Activo", "Activo", 50, Types.ColumnTypes.CheckBox, Types.EditType.CheckBox));
            }
            if (fl.Contains("IdSucursal") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdSucursal", "IdSucursal", true));
            }
            if (fl.Contains("IdEmpresa") || _fieldList == null)
            {
                sb.Append(LayoutBuilder.GetRow(i++, "IdEmpresa", "IdEmpresa", true));
            }

            /*if ( fl.Contains( "FechaCreacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "FechaCreacion", "FechaCreacion",true ) );
             * if ( fl.Contains( "IdConexionCreacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdConexionCreacion", "IdConexionCreacion",true ) );
             * if ( fl.Contains( "UltimaModificacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "UltimaModificacion", "UltimaModificacion",true ) );
             * if ( fl.Contains( "IdConexionUltimaModificacion" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdConexionUltimaModificacion", "IdConexionUltimaModificacion",true ) );
             * if ( fl.Contains( "IdReservado" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "IdReservado", "IdReservado",true ) );
             * if ( fl.Contains( "RowId" ) || _fieldList == null ) sb.Append( LayoutBuilder.GetRow( i++, "RowId", "RowId" ,true) );
             */
            sb.Append(LayoutBuilder.GetFooter());

            return(sb.ToString());
        }