1.0.9
This commit is contained in:
@@ -31,7 +31,7 @@ public class BarReceiptConverter
|
||||
|
||||
//string serverIdLine = $"{kitchenReceipt.WaiterId}";
|
||||
//commands.Add(new PrintCommand(Center(serverIdLine, false)));
|
||||
|
||||
commands.Add(new PrintCommand(""));
|
||||
string tableLine = $"Tisch: {kitchenReceipt.TableNumber}";
|
||||
commands.Add(new PrintCommand(Center(tableLine, true), true, true));
|
||||
|
||||
|
||||
@@ -27,6 +27,16 @@ public class FinalReceipt
|
||||
public string GoodbyeMessageLine1 { get; set; }
|
||||
public string GoodbyeMessageLine2 { get; set; }
|
||||
public List<PaymentTerminalReceipt> TerminalReceipts { get; set; } = new List<PaymentTerminalReceipt>();
|
||||
public DiscountInfo? DiscountInfo { get; set; }
|
||||
}
|
||||
|
||||
public class DiscountInfo
|
||||
{
|
||||
public string Description { get; set; }
|
||||
public decimal Amount { get; set; }
|
||||
public string Currency { get; set; }
|
||||
public decimal? AmountInAlternateCurrency { get; set; }
|
||||
public string AlternateCurrency { get; set; }
|
||||
}
|
||||
|
||||
public class FinalReceiptItem
|
||||
|
||||
@@ -77,6 +77,14 @@ public class ReceiptConverter
|
||||
commands.Add(new PrintCommand(""));
|
||||
}
|
||||
|
||||
// Discount
|
||||
//if (finalReceipt.DiscountInfo != null && finalReceipt.DiscountInfo.Amount > 0)
|
||||
//{
|
||||
|
||||
// commands.Add(new PrintCommand(finalReceipt.DiscountInfo.Description.PadLeft(_lineWidth/2)));
|
||||
// commands.Add(new PrintCommand(""));
|
||||
//}
|
||||
|
||||
// Split payments
|
||||
if (finalReceipt.SplitPayments != null && finalReceipt.SplitPayments.Count > 0)
|
||||
{
|
||||
@@ -118,7 +126,10 @@ public class ReceiptConverter
|
||||
|
||||
// Footer info
|
||||
commands.Add(new PrintCommand($"Bedient von:".PadLeft(_lineWidth / 2) + $" {finalReceipt.WaiterName}"));
|
||||
commands.Add(new PrintCommand($"Terminal:".PadLeft(_lineWidth / 2) + $" {finalReceipt.Terminal}"));
|
||||
|
||||
if(!string.IsNullOrEmpty(finalReceipt.Terminal))
|
||||
commands.Add(new PrintCommand($"Terminal:".PadLeft(_lineWidth / 2) + $" {finalReceipt.Terminal}"));
|
||||
|
||||
commands.Add(new PrintCommand($"Tisch:".PadLeft(_lineWidth / 2)+$" {finalReceipt.TableNumber}"));
|
||||
commands.Add(new PrintCommand(""));
|
||||
commands.Add(new PrintCommand(""));
|
||||
|
||||
@@ -8,7 +8,7 @@ public class InvoiceReceipt
|
||||
public string Phone { get; set; }
|
||||
public string ReceiptNumber { get; set; }
|
||||
public DateTime DateTime { get; set; }
|
||||
public int Guests { get; set; }
|
||||
public int? Guests { get; set; }
|
||||
public List<ReceiptItem> Items { get; set; } = new List<ReceiptItem>();
|
||||
public decimal Total { get; set; }
|
||||
public string Currency { get; set; }
|
||||
|
||||
@@ -34,7 +34,10 @@ public class ReceiptConverter
|
||||
receiptLine += $"{invoiceReceipt.DateTime:HH:mm dd.MM.yyyy}".PadLeft(_lineWidth / 2);
|
||||
|
||||
commands.Add(new PrintCommand(receiptLine,isBold:true));
|
||||
commands.Add(new PrintCommand($"Guests: {invoiceReceipt.Guests}"));
|
||||
|
||||
if(invoiceReceipt.Guests != null)
|
||||
commands.Add(new PrintCommand($"Guests: {invoiceReceipt.Guests}"));
|
||||
|
||||
commands.Add(new PrintCommand(""));
|
||||
|
||||
// Items
|
||||
|
||||
Reference in New Issue
Block a user