public void Print(ICollection <TicketDetailDto> details) { if (details.Count == 0 || !IsActive) { return; } var office = _dataService.CurrentOffice; var restaurant = _dataService.Restaurant; using (var document = PurchaseDocument.Generate(details, office, restaurant)) { document.PrinterSettings.PrinterName = DefaultPrinter; document.Print(); } }
public ActionResult <PurchaseDocument> Create(PurchaseDocument purchaseDocument) { _purchaseService.Create(purchaseDocument); return(purchaseDocument); }
public PurchaseDocument Create(PurchaseDocument purchaseDocument) { _dataRepository.InsertRecord(_userTable, purchaseDocument); return(purchaseDocument); }