public Int64 Insert(PaidOutDetails Details) { try { Save(Details); Int64 iID = Int64.Parse(base.getLAST_INSERT_ID(this)); TerminalReport clsTerminalReport = new TerminalReport(base.Connection, base.Transaction); clsTerminalReport.UpdatePaidOut(Details); CashierReports clsCashierReport = new CashierReports(base.Connection, base.Transaction); clsCashierReport.UpdatePaidOut(Details); return iID; } catch (Exception ex) { throw base.ThrowException(ex); } }
public void Insert(CashCountDetails[] Details) { try { if (Details.Length > 0) { decimal Amount = 0; foreach(CashCountDetails details in Details) { Insert(details); Amount += details.DenominationAmount; } CashierReports clsCashierReport = new CashierReports(base.Connection, base.Transaction); clsCashierReport.UpdateCashCount(Details[0].BranchDetails.BranchID, Details[0].CashierID, Details[0].TerminalNo, Amount); } } catch (Exception ex) { throw base.ThrowException(ex); } }