d8ecec8bb6
BillInventory Renamed. Refactored Bill to be more usable. Added Bill Detail Report. Added Open Bill and Bill Details Roles. Zero Rate Products have Yellow background Color. Refactored UserBI, FoodTableBI, ModifierBI, PrintLocationBI, ProductBI, ProductGroupBI, TaxBI, UserBI, Cached the Products List. Product and Product Group Form Working.
26 lines
962 B
C#
26 lines
962 B
C#
using System.Configuration;
|
|
using Tanshu.Accounts.Entities;
|
|
|
|
namespace Tanshu.Accounts.Repository
|
|
{
|
|
public class PrintLocationBI : FluentBase<PrintLocation>
|
|
{
|
|
public static PrintLocation BasePrinter
|
|
{
|
|
get
|
|
{
|
|
var location = ConfigurationManager.AppSettings["Location"].ToLowerInvariant();
|
|
using (var bi = new PrintLocationBI())
|
|
return bi.Get(x => x.Location == location && x.ProductGroup == null);
|
|
}
|
|
}
|
|
public static PrintLocation KotPrinter(int productGroupID)
|
|
{
|
|
var location = ConfigurationManager.AppSettings["Location"].ToLowerInvariant();
|
|
using (var bi = new PrintLocationBI())
|
|
return bi.Get(x => x.Location == location && x.ProductGroup.ProductGroupID == productGroupID) ??
|
|
bi.Get(x => x.Location == location && x.ProductGroup == null);
|
|
}
|
|
}
|
|
}
|