Fully Working build with Different print locations and table loading. Pending: Bill Settlement, Modifiers, etc.
This commit is contained in:
@ -219,15 +219,14 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
throw new PermissionException("You are not allowed to print KOT");
|
||||
|
||||
if (!finalBill)
|
||||
Accounts.Print.Thermal.PrintWaiterKot("KOT", voucherID, bill.Values.ToList());
|
||||
Accounts.Print.Thermal.PrintKot(voucherID, bill.Values.ToList());
|
||||
else
|
||||
{
|
||||
using (RoleBI roleBI = RoleFactoryBI.GetRoleBI(Roles.SALES_PRINT_BILL))
|
||||
{
|
||||
if (roleBI.IsAllowed)
|
||||
{
|
||||
Accounts.Print.Thermal.PrintBill(Session.printer(), true, voucherID, bill.Values.ToList());
|
||||
Accounts.Print.Thermal.PrintCustomerKot("KOT", voucherID, bill.Values.ToList());
|
||||
Accounts.Print.Thermal.PrintBill(true, voucherID, bill.Values.ToList());
|
||||
|
||||
}
|
||||
else
|
||||
@ -267,12 +266,13 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
}
|
||||
private void ShowAmount()
|
||||
{
|
||||
decimal grossTax = bill.Values.Sum(b => b.TaxAmount);
|
||||
decimal discount = bill.Values.Sum(b => b.DiscountAmount);
|
||||
decimal taxAmount = bill.Values.Sum(b => b.TaxAmount);
|
||||
decimal discountAmount = bill.Values.Sum(b => b.DiscountAmount);
|
||||
decimal grossAmount = bill.Values.Sum(b => b.GrossAmount);
|
||||
decimal amount = bill.Values.Sum(b => b.Value);
|
||||
decimal valueAmount = bill.Values.Sum(b => b.Value);
|
||||
decimal serviceChargeAmount = bill.Values.Sum(b => b.ServiceChargeAmount);
|
||||
//bill.Values.ToList();
|
||||
saleForm.ShowAmount(grossTax, discount, grossAmount, amount, bill.Values.ToList());
|
||||
saleForm.ShowAmount(discountAmount, grossAmount, serviceChargeAmount, taxAmount, valueAmount, bill.Values.ToList());
|
||||
}
|
||||
public void SetDiscount(SalesBillItemBO product, decimal discount)
|
||||
{
|
||||
@ -448,6 +448,26 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
internal void SettleBill()
|
||||
{
|
||||
if (billInfo == null)
|
||||
return;
|
||||
SettleOptions option = SettleOptions.Cancel;
|
||||
using (BillSettleForm frm = new BillSettleForm())
|
||||
{
|
||||
frm.ShowDialog();
|
||||
option = frm.optionChosen;
|
||||
}
|
||||
switch (option)
|
||||
{
|
||||
case SettleOptions.Cancel:
|
||||
break;
|
||||
case SettleOptions.Cash:
|
||||
|
||||
}
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
// How to load a bill
|
||||
|
||||
@ -11,7 +11,7 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
void ClearBill(Dictionary<BillItemKey, SalesBillItemBO> bill);
|
||||
void SetCustomerDisplay(string name);
|
||||
void CloseWindow();
|
||||
void ShowAmount(decimal grossTax, decimal discount, decimal grossAmount, decimal amount, List<SalesBillItemBO> bill);
|
||||
void ShowAmount(decimal discountAmount, decimal grossAmount, decimal serviceChargeAmount, decimal taxAmount, decimal valueAmount, List<SalesBillItemBO> bill);
|
||||
void ShowInfo(string billID, string kotID, DateTime creationDate, DateTime date, DateTime lastEditDate, string customer, string tableID, Guid waiterID, string waiter);
|
||||
void SetUserName(string name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user