public addProduct()
 {
     InitializeComponent();
     this.Text = "Agregar Producto";
     this.cbar = new cb();
     this.db   = new dbop();
     this.setAtribs();
 }
 public addProduct(midformProduct origen)
 {
     InitializeComponent();
     this.Text   = "Agregar Producto";
     this.origen = origen;
     this.origen.addbtn.Enabled = false;
     this.FormClosed           += (x, y) => { this.origen.addbtn.Enabled = true; };
     this.cbar = new cb();
     this.db   = new dbop();
     this.setAtribs();
     this.stopBounds();
 }
Exemple #3
0
        public globalTicket(List <detallesTicket> dt, venta xventa)
        {
            this.xventa   = xventa;
            this.detalles = dt;
            this.codebar  = new cb();
            this.xform    = new Form();
            this.db       = new dbop();
            this.xcliente = this.db.getclientAsobject(this.xventa.idcliente);

            this.xtienda = this.db.getTienda();

            this.myfont = new Font("Lucida Console", 7, FontStyle.Regular);

            this.brush      = new SolidBrush(Color.Black);
            this.marginLeft = 5;
            this.vertical   = 0;
            this.widthDoc   = inchesCM * 100 * 8; // AUTOMATIZAR PARA FORMATOS
            this.heightDoc  = 0;
            this.setAttribs(dt.Count);

            this.nombretienda   = this.xtienda.nombre.ToUpper();
            this.rfc            = "RFC " + this.xtienda.rfc;
            this.direccion      = this.xtienda.calle.ToUpper() + " #" + this.xtienda.numero.ToString().ToUpper();
            this.colonia        = "COL. " + this.xtienda.colonia.ToUpper();
            this.ciudad         = (this.xtienda.ciudad + "," + this.xtienda.estado).ToUpper();
            this.telefono       = "TEL. " + this.xtienda.telefono.ToUpper();
            this.fecha          = ">>FECHA: " + this.xventa.fecha.ToString("dd/MM/yyyy", CultureInfo.InvariantCulture) + " >>HORA: " + this.xventa.hora.ToString();
            this.numticket      = ">>TICKET #: " + this.db.getticketid(this.xventa.idventa).ToString();
            this.clientename    = ">>CLIENTE: " + this.xcliente.nombre.ToUpper();
            this.subtotalletra  = "SUBTOTAL $";
            this.subtotal       = this.xventa.subtotal.ToString("F1").Replace(",", ".");
            this.totalletra     = "TOTAL $";
            this.total          = this.xventa.total.ToString("F2").Replace(",", ".");
            this.descuentoletra = "DESCUENTO $";
            this.descuento      = this.xventa.descuentoextra.ToString("F1").Replace(",", ".");

            this.ivaletra = "IVA $";
            this.iva      = (this.xventa.subtotal / 100 * 16).ToString("F1").Replace(",", ".");

            this.precioletra = "PROXIMAMENTE";
            this.leyenda     = "¡Gracias por su compra!";

            this.cantidad   = "Cant.";
            this.producto   = "Producto";
            this.preciounit = "P.Unit";
            this.importe    = "Importe";

            this.xconvierte  = new convierte();
            this.xtotalletra = this.xconvierte.getstring(this.xventa.total).ToUpper() + "MN.";
        }
        public printTicket(venta xventa, tienda xtienda)
        {
            this.xtienda   = xtienda;
            this.xventa    = xventa;
            this.db        = new dbop();
            this.reporte   = new rptticket();
            this.translate = new convierte();
            this.codbar    = new cb();

            this.xcliente = this.db.getclientAsobject(this.xventa.idcliente);

            this.pathcbar = Path.Combine(genericDefinitions.TICKETLOGOSPATH + @"\logocbar.png");
            this.pathlogo = Path.Combine(genericDefinitions.TICKETLOGOSPATH + @"\logotienda.png");

            this.widthcbar  = (int)(widthcbar * 50 / 2.54);
            this.heightcbar = (int)(heightcbar * 50 / 2.54);
        }
Exemple #5
0
    public void AddRequest(string file, string localpath, cb callback, long offset, UpdateFile item)
    {
        if (file == null || file.Length == 0 || localpath == null || localpath.Length == 0)
        {
            //Debug.LogError("AddRequest Error Invalid Param");
            return;
        }
        localpath = localpath.Replace("\\", "/");
        int nDirectoryIndex = localpath.LastIndexOf('/');

        Directory.CreateDirectory(localpath.Substring(0, nDirectoryIndex));
        HttpManager.InitHttpModule();
        HttpRequest req = null;

        //dont allow request same file again
        lock (RequestMap)
        {
            if (DownloadMap.TryGetValue(strURIBase + file, out req))
            {
                if (req.bDone)
                {
                    return;
                }
                else
                {
                    req.order = RequestStatus.Normal;
                }
                return;
            }

            if (!RequestMap.TryGetValue(strURIBase + file, out req))
            {
                req = new HttpRequest(file, this, callback, offset, localpath, item);
                RequestMap.Add(strURIBase + file, req);
            }
            else
            {
                req.order = RequestStatus.Normal;
            }
        }
    }
Exemple #6
0
 public printCbar()
 {
     this.codabar = new cb();
     this.db      = new dbop();
 }
Exemple #7
0
 public DurableItemDescriptor(cb instance) : base(instance)
 {
     _internal = instance;
 }
Exemple #8
0
 public AgentTypeDescriptor(cb instance)
 {
     _internal = instance;
 }