示例#1
0
        /// <summary>
        /// Prints end of sales X full receipt
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public void PrintEndOfDaySalesFullReceipt(object sender, PrintPageEventArgs e)
        {
            Graphics graphic = e.Graphics;

            Font font          = new Font("Courier New", 9, System.Drawing.FontStyle.Bold);
            Font storeNameFont = new Font("Courier New", 14, System.Drawing.FontStyle.Bold);
            Font storeInfoFont = new Font("Courier New", 8, System.Drawing.FontStyle.Bold);

            var   buf                 = string.Empty;
            float fontHeight          = 9.0f + 4.5f;
            float storeNameFontHeight = storeNameFont.GetHeight();
            float storeInfoFontHeight = 8 + 6f;

            //Parse Description
            var commentsLines = new List <string>();

            if (EndOfDayAmountData.Comments == null)
            {
                commentsLines.Add(" ");
            }
            else
            {
                commentsLines = Formatter.BreakDownString(EndOfDayAmountData.Comments, 35);
            }

            int startX = 5;
            int startY = 1;
            int offset = 10;

            int itemsNumber = 0;

            //Header business info
            buf = Formatter.AlignToCenter(Pos.BusinessName, 19);
            graphic.DrawString(buf, storeNameFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeNameFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalName);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalType + "  " + Pos.FiscalNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalStreetAddress);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black),
                               startX, startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalCityAndZipCode + "  " + Pos.FiscalPhoneNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;

            buf = Formatter.AlignToCenter(Pos.FiscalEmail);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Ticket numbers and range
            graphic.DrawString("Corte X    " + "Folio " + EndOfDayReceiptData.FirstReceiptNumber.ToString() + " al " +
                               EndOfDayReceiptData.LastReceiptNumber, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            Thread.CurrentThread.CurrentCulture = new CultureInfo("es-MX");
            var date = DateTime.Now.ToString("g");

            var ticketNumber = "No. " + (Pos.LastCorteZNumber + 1).ToString();

            graphic.DrawString(ticketNumber.PadRight(18) + date, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Sales per category loop
            foreach (var catInfo in EndOfDayReceiptData.SalesInfoPerCategory)
            {
                //mimic a product just to use the ToString overwrite
                var cat = new ProductBase()
                {
                    Category         = catInfo.Item1,
                    LastQuantitySold = catInfo.Item2,
                    Price            = catInfo.Item3
                };
                if (cat.LastAmountSold != 0 || cat.Price != 0)
                {
                    graphic.DrawString(cat.ToString(ReceiptType.DailyRegular), font, new SolidBrush(Color.Black), startX, startY + offset);
                    offset = offset + (int)fontHeight;
                }
            }

            offset = offset + 10;

            graphic.DrawString("********** Total Ventas ***********", font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Puntos Usados: ".PadLeft(20) + string.Format("{0}", EndOfDayReceiptData.PointsTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total Articulos: ".PadLeft(20) + string.Format("{0}", EndOfDayReceiptData.TotalItemsSold), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Efectivo MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.CashTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Tarjeta MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.CardTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Otro Metodo MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.OtherTotal +
                                                                               EndOfDayReceiptData.BankTotal + EndOfDayReceiptData.CheckTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.TotalAmountSold), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("********** Devoluciones ***********", font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total Articulos: ".PadLeft(20) + string.Format("{0}", EndOfDayReceiptData.TotalReturnItems), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Efectivo MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.ReturnsCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Tarjeta MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.ReturnsCard), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.ReturnsCard + EndOfDayReceiptData.ReturnsCash),
                               font, new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("*********** Total Caja ************", font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Monedas Pesos: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.MxnCoins), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 20: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn20), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 50: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn50), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 100: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn100), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 200: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn200), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 500: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn500), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Pesos 1000: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Mxn1000), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total Efectivo MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.MxnTotalCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Monedas Dolar: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.UsdCoins), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 1: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd1), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 5: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd5), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 10: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd10), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 20: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd20), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 50: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd50), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Dolar 100: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.Usd100), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Total Efectivo USD: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.UsdTotalCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("********** Total Gastos ***********", font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Efectivo MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.ExpensesCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Totales MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.ExpensesTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("************* Resumen *************", font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Usuario: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.User), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Tipo de Corte: ".PadLeft(20) + string.Format("{0}", EndOfDayAmountData.EndOfSalesReceiptType), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Tipo de Cambio: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.ExchangeRate), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Caja Inicio MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.InitialCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Caja Nueva MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.NewInitialCash), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Diferencia MXN: ".PadLeft(20) + string.Format("{0:c}", EndOfDayAmountData.Delta), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;
            offset = offset + (int)fontHeight + 1;

            graphic.DrawString("Comentarios: ", font, new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 1;

            foreach (var commentLine in commentsLines)
            {
                graphic.DrawString(string.Format("{0}", commentLine), font, new SolidBrush(Color.Black), startX, startY + offset);

                offset = offset + (int)fontHeight + 1;
            }

            graphic.DrawString(string.Format("  Final Corte {0} {1}", EndOfDayAmountData.EndOfSalesReceiptType, date), storeInfoFont, new SolidBrush(Color.Black),
                               startX, startY + offset);
            offset = offset + (int)storeInfoFontHeight;
        }
示例#2
0
        /// <summary>
        /// Prints regular sale receipt
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public void printSampleReceipt(object sender, PrintPageEventArgs e)
        {
            Graphics graphic = e.Graphics;

            Font font          = new Font("Courier New", 8, System.Drawing.FontStyle.Bold);
            Font storeNameFont = new Font("Courier New", 14, System.Drawing.FontStyle.Bold);
            Font storeInfoFont = new Font("Courier New", 8, System.Drawing.FontStyle.Bold);

            var   buf                 = string.Empty;
            float fontHeight          = font.GetHeight();
            float storeNameFontHeight = storeNameFont.GetHeight();
            float storeInfoFontHeight = storeInfoFont.GetHeight();

            int startX = 5;
            int startY = 5;
            int offset = 15;

            int itemsNumber = 0;

            //Ticket header with business information
            buf = Formatter.AlignToCenter(Pos.BusinessName, 19);
            graphic.DrawString(buf, storeNameFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeNameFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalName);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalType + " " + Pos.FiscalNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalStreetAddress);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black),
                               startX, startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalCityAndZipCode + " " + Pos.FiscalPhoneNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalEmail);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Username
            graphic.DrawString("Usuario: " + SalesData.User.UserName, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 2;

            //Date and ticket number
            Thread.CurrentThread.CurrentCulture = new CultureInfo("es-MX");
            var date         = DateTime.Now.ToString("g");
            var ticketNumber = "No. " + Pos.LastReceiptNumber.ToString();

            graphic.DrawString(ticketNumber.PadRight(14) + date, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Product loop
            foreach (var product in _products)
            {
                //TODO: poner descripcion en vez de solo la categoria como default o opcion a elegir
                string productCategory    = product.Category.PadRight(15);
                string productDescription = product.Category.PadRight(15);
                string productTotal       = string.Format("{0:c}", product.Price);
                string productLine        = productDescription + productTotal;
                string detailsLine        = string.Empty;

                if (product.Code != null)
                {
                    detailsLine = "- " + product.Code + " " + Formatter.TrimToFixedLength(product.Description, 33 - product.Code.Length);
                }
                else
                {
                    detailsLine = "- 0000 " + Formatter.TrimToFixedLength(product.Description, 26);
                }

                //details line
                graphic.DrawString(detailsLine, font, new SolidBrush(Color.Black), startX, startY + offset);

                offset = offset + (int)fontHeight;

                ////product line
                //graphic.DrawString(product.ToString(), font, new SolidBrush(Color.Black), startX, startY + offset);

                //offset = offset + (int)fontHeight;

                productLine = string.Format("{0,-11} {1,-3} {2,-10:c} {3,-10:c}", Formatter.TrimToFixedLength(product.Category, 11), product.LastQuantitySold.ToString() + "x",
                                            product.Price, product.Price * product.LastQuantitySold);

                graphic.DrawString(productLine, font, new SolidBrush(Color.Black), startX, startY + offset);

                offset = offset + (int)fontHeight;

                if (product.Category != "Puntos")
                {
                    itemsNumber = itemsNumber + product.LastQuantitySold;
                }
            }

            offset = offset + 20;

            buf = string.Format("{0,-14} {1,-8:c}", "Total:", Transaction.TotalDue);
            graphic.DrawString(buf, font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight;

            buf = string.Format("{0,-14} {1,-8:c}", Transaction.PaymentType.ToString() + ":", Transaction.AmountPaid);
            graphic.DrawString(buf, font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight;

            buf = string.Format("{0,-14} {1,-8:c}", "Cambio:", Transaction.ChangeDue);
            graphic.DrawString(buf, font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight;

            buf = string.Format("{0,-14} {1,-8}", "Articulos:", itemsNumber);
            graphic.DrawString(buf, font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            //Customer info, if available
            if (SalesData.Customer != null)
            {
                offset = offset + (int)fontHeight + 20;

                buf = string.Format("{0,-17} {1,-8}", "Cliente:", SalesData.Customer.Name);
                graphic.DrawString(buf, font,
                                   new SolidBrush(Color.Black), startX, startY + offset);

                offset = offset + (int)fontHeight;

                buf = string.Format("{0,-17} {1,-8:c}", "Pts Obtenidos:", SalesData.PointsObtained);
                graphic.DrawString(buf, font,
                                   new SolidBrush(Color.Black), startX, startY + offset);

                offset = offset + (int)fontHeight;

                buf = string.Format("{0,-17} {1,-8:c}", "Pts Disponibles:", SalesData.Customer.PointsAvailable);
                graphic.DrawString(buf, font,
                                   new SolidBrush(Color.Black), startX, startY + offset);
            }

            offset = offset + (int)fontHeight + 20;

            var comments = Formatter.BreakDownString(Pos.Comments, 35);

            foreach (var comment in comments)
            {
                graphic.DrawString(comment, font,
                                   new SolidBrush(Color.Black), startX, startY + offset);
                offset = offset + (int)fontHeight;
            }

            offset = offset + (int)fontHeight + 20;

            buf = Formatter.AlignToCenter(Pos.FooterMessage);

            //Footer message
            graphic.DrawString(buf, font, new SolidBrush(Color.Black), startX,
                               startY + offset);

            offset = offset + (int)fontHeight + 5;
        }
示例#3
0
        /// <summary>
        /// Prints end of day Z short receipt
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public void PrintEndOfDaySalesReceipt(object sender, PrintPageEventArgs e)
        {
            Graphics graphic = e.Graphics;

            Font font          = new Font("Courier New", 9, System.Drawing.FontStyle.Bold);
            Font storeNameFont = new Font("Courier New", 14, System.Drawing.FontStyle.Bold);
            Font storeInfoFont = new Font("Courier New", 8, System.Drawing.FontStyle.Bold);

            var   buf                 = string.Empty;
            float fontHeight          = font.GetHeight();
            float storeNameFontHeight = storeNameFont.GetHeight();
            float storeInfoFontHeight = storeInfoFont.GetHeight();

            int startX = 5;
            int startY = 2;
            int offset = 10;

            int itemsNumber = 0;

            //Ticket header with business information
            buf = Formatter.AlignToCenter(Pos.BusinessName, 19);
            graphic.DrawString(buf, storeNameFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeNameFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalName);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalType + " " + Pos.FiscalNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalStreetAddress);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black),
                               startX, startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalCityAndZipCode + " " + Pos.FiscalPhoneNumber);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight;
            buf    = Formatter.AlignToCenter(Pos.FiscalEmail);
            graphic.DrawString(buf, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Receipt number and tickets number range
            graphic.DrawString("Corte Z    " + "Folio " + EndOfDayReceiptData.FirstReceiptNumber.ToString() + " al " +
                               EndOfDayReceiptData.LastReceiptNumber, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            Thread.CurrentThread.CurrentCulture = new CultureInfo("es-MX");
            var date = DateTime.Now.ToString("g");

            var ticketNumber = "No. " + Pos.LastCorteZNumber.ToString();

            graphic.DrawString(ticketNumber.PadRight(18) + date, storeInfoFont, new SolidBrush(Color.Black), startX,
                               startY + offset);
            offset = offset + (int)storeInfoFontHeight + 10;

            //Gets each category information
            foreach (var catInfo in EndOfDayReceiptData.SalesInfoPerCategory)
            {
                //mimic a product just to use the ToString overwrite
                var cat = new ProductBase()
                {
                    Category         = catInfo.Item1,
                    LastQuantitySold = catInfo.Item2,
                    Price            = catInfo.Item3
                };
                //product line
                if (cat.LastQuantitySold != 0 || cat.Price != 0)
                {
                    graphic.DrawString(cat.ToString(ReceiptType.DailyRegular), font, new SolidBrush(Color.Black), startX, startY + offset);
                    offset = offset + (int)fontHeight;
                }
            }

            offset = offset + 10;

            graphic.DrawString("Articulos: ".PadLeft(20) + string.Format("{0}", EndOfDayReceiptData.TotalItemsSold), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 5;

            graphic.DrawString("Efectivo: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.CashTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 5;

            graphic.DrawString("Tarjeta: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.CardTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 5;

            graphic.DrawString("Otro Metodo: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.OtherTotal +
                                                                           EndOfDayReceiptData.BankTotal + EndOfDayReceiptData.BankTotal), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 5;

            graphic.DrawString("Total: ".PadLeft(20) + string.Format("{0:c}", EndOfDayReceiptData.TotalAmountSold), font,
                               new SolidBrush(Color.Black), startX, startY + offset);

            offset = offset + (int)fontHeight + 5;

            graphic.DrawString(string.Format("  Final Corte {0} {1}", EndOfDayAmountData.EndOfSalesReceiptType, date), storeInfoFont, new SolidBrush(Color.Black),
                               startX, startY + offset);
            offset = offset + (int)storeInfoFontHeight;
        }