Ejemplo n.º 1
0
        /// <summary>
        /// Builds and formats a receipt based on the current response in memory.
        /// </summary>
        /// <returns>A formatted receipt</returns>
        public async Task <string> printEMVReceiptNoSig()
        {
            string receiptText = formatTransactionData();

            receiptText += Environment.NewLine + formatEMVData();

            ReceiptPrinter rp = new ReceiptPrinter();

            rp.setTransactionData(receiptText);
            return(rp.ToStringNoSig());
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Creates an EMV compliant receipt
        /// </summary>
        /// <returns>String representation of a receipt.</returns>
        public async Task <string> printEMVReceipt()
        {
            log.Write("Printing EMV Receipt");
            string receiptText = formatTransactionData();

            receiptText += Environment.NewLine + formatEMVData();

            ReceiptPrinter rp = new ReceiptPrinter();

            rp.setTransactionData(receiptText);
            if (sigRequired)
            {
                return(rp.ToString());
            }
            else
            {
                return(rp.ToStringNoSig());
            }
        }