public void UpdateTransactionSales(CashierReportDetails Details) { try { MySqlCommand cmd = new MySqlCommand(); cmd.CommandType = System.Data.CommandType.Text; string SQL = "CALL procCashierReportUpdateTransactionSales(@BranchID, @TerminalNo,@CashierID," + "@NetSales, " + "@GrossSales, " + "@TotalDiscount, " + "@SNRDiscount, " + "@PWDDiscount, " + "@OtherDiscount, " + "@TotalCharge, " + "@DailySales, " + "@ItemSold, " + "@QuantitySold, " + "@GroupSales, " + "@VATExempt, " + "@NonVATableAmount, " + "@VATableAmount, " + "@ZeroRatedSales, " + "@VAT, " + "@EVATableAmount, " + "@NonEVATableAmount, " + "@EVAT, " + "@LocalTax, " + "@CashSales, " + "@ChequeSales, " + "@CreditCardSales, " + "@CreditSales, " + "@CreditPayment, " + "@CreditPaymentCash, " + "@CreditPaymentCheque, " + "@CreditPaymentCreditCard, " + "@CreditPaymentDebit, " + "@DebitPayment, " + "@RewardPointsPayment, " + "@RewardConvertedPayment, " + "@CashInDrawer, " + "@VoidSales, " + "@RefundSales, " + "@ItemsDiscount, " + "@SNRItemsDiscount, " + "@PWDItemsDiscount, " + "@OtherItemsDiscount, " + "@SubTotalDiscount, " + "@NoOfCashTransactions, " + "@NoOfChequeTransactions, " + "@NoOfCreditCardTransactions, " + "@NoOfCreditTransactions, " + "@NoOfCombinationPaymentTransactions, " + "@NoOfCreditPaymentTransactions, " + "@NoOfDebitPaymentTransactions, " + "@NoOfClosedTransactions, " + "@NoOfRefundTransactions, " + "@NoOfVoidTransactions, " + "@NoOfRewardPointsPayment, " + "@NoOfTotalTransactions, " + "@NoOfDiscountedTransactions, " + "@NegativeAdjustments, " + "@NoOfNegativeAdjustmentTransactions, " + "@NoOfConsignmentTransactions, " + "@NoOfConsignmentRefundTransactions, " + "@NoOfWalkInTransactions, " + "@NoOfWalkInRefundTransactions, " + "@NoOfOutOfStockTransactions, " + "@NoOfOutOfStockRefundTransactions, " + "@PromotionalItems, " + "@CreditSalesTax);"; cmd.Parameters.AddWithValue("NetSales", Details.NetSales); cmd.Parameters.AddWithValue("GrossSales", Details.GrossSales); cmd.Parameters.AddWithValue("TotalDiscount", Details.TotalDiscount); cmd.Parameters.AddWithValue("SNRDiscount", Details.SNRDiscount); cmd.Parameters.AddWithValue("PWDDiscount", Details.PWDDiscount); cmd.Parameters.AddWithValue("OtherDiscount", Details.OtherDiscount); cmd.Parameters.AddWithValue("TotalCharge", Details.TotalCharge); cmd.Parameters.AddWithValue("DailySales", Details.DailySales); cmd.Parameters.AddWithValue("ItemSold", Details.ItemSold); cmd.Parameters.AddWithValue("QuantitySold", Details.QuantitySold); cmd.Parameters.AddWithValue("GroupSales", Details.GroupSales); cmd.Parameters.AddWithValue("VATExempt", Details.VATExempt); cmd.Parameters.AddWithValue("NonVATableAmount", Details.NonVATableAmount); cmd.Parameters.AddWithValue("VATableAmount", Details.VATableAmount); cmd.Parameters.AddWithValue("ZeroRatedSales", Details.ZeroRatedSales); cmd.Parameters.AddWithValue("VAT", Details.VAT); cmd.Parameters.AddWithValue("EVATableAmount", Details.EVATableAmount); cmd.Parameters.AddWithValue("NonEVATableAmount", Details.NonEVATableAmount); cmd.Parameters.AddWithValue("EVAT", Details.EVAT); cmd.Parameters.AddWithValue("LocalTax", Details.LocalTax); cmd.Parameters.AddWithValue("CashSales", Details.CashSales); cmd.Parameters.AddWithValue("ChequeSales", Details.ChequeSales); cmd.Parameters.AddWithValue("CreditCardSales", Details.CreditCardSales); cmd.Parameters.AddWithValue("CreditSales", Details.CreditSales); cmd.Parameters.AddWithValue("CreditPayment", Details.CreditPayment); cmd.Parameters.AddWithValue("CreditPaymentCash", Details.CreditPaymentCash); cmd.Parameters.AddWithValue("CreditPaymentCheque", Details.CreditPaymentCheque); cmd.Parameters.AddWithValue("CreditPaymentCreditCard", Details.CreditPaymentCreditCard); cmd.Parameters.AddWithValue("CreditPaymentDebit", Details.CreditPaymentDebit); cmd.Parameters.AddWithValue("DebitPayment", Details.DebitPayment); cmd.Parameters.AddWithValue("RewardPointsPayment", Details.RewardPointsPayment); cmd.Parameters.AddWithValue("RewardConvertedPayment", Details.RewardConvertedPayment); cmd.Parameters.AddWithValue("CashInDrawer", Details.CashInDrawer == 0 ? Details.CashSales : Details.CashInDrawer); cmd.Parameters.AddWithValue("VoidSales", Details.VoidSales); cmd.Parameters.AddWithValue("RefundSales", Details.RefundSales); cmd.Parameters.AddWithValue("ItemsDiscount", Details.ItemsDiscount); cmd.Parameters.AddWithValue("SNRItemsDiscount", Details.SNRItemsDiscount); cmd.Parameters.AddWithValue("PWDItemsDiscount", Details.PWDItemsDiscount); cmd.Parameters.AddWithValue("OtherItemsDiscount", Details.OtherItemsDiscount); cmd.Parameters.AddWithValue("SubTotalDiscount", Details.SubTotalDiscount); cmd.Parameters.AddWithValue("NoOfCashTransactions", Details.NoOfCashTransactions); cmd.Parameters.AddWithValue("NoOfChequeTransactions", Details.NoOfChequeTransactions); cmd.Parameters.AddWithValue("NoOfCreditCardTransactions", Details.NoOfCreditCardTransactions); cmd.Parameters.AddWithValue("NoOfCreditTransactions", Details.NoOfCreditTransactions); cmd.Parameters.AddWithValue("NoOfCombinationPaymentTransactions", Details.NoOfCombinationPaymentTransactions); cmd.Parameters.AddWithValue("NoOfCreditPaymentTransactions", Details.NoOfCreditPaymentTransactions); cmd.Parameters.AddWithValue("NoOfDebitPaymentTransactions", Details.NoOfDebitPaymentTransactions); cmd.Parameters.AddWithValue("NoOfClosedTransactions", Details.NoOfClosedTransactions); cmd.Parameters.AddWithValue("NoOfRefundTransactions", Details.NoOfRefundTransactions); cmd.Parameters.AddWithValue("NoOfVoidTransactions", Details.NoOfVoidTransactions); cmd.Parameters.AddWithValue("NoOfRewardPointsPayment", Details.NoOfRewardPointsPayment); cmd.Parameters.AddWithValue("NoOfTotalTransactions", Details.NoOfTotalTransactions); cmd.Parameters.AddWithValue("NoOfDiscountedTransactions", Details.NoOfDiscountedTransactions); cmd.Parameters.AddWithValue("NegativeAdjustments", Details.NegativeAdjustments); cmd.Parameters.AddWithValue("NoOfNegativeAdjustmentTransactions", Details.NoOfNegativeAdjustmentTransactions); cmd.Parameters.AddWithValue("NoOfConsignmentTransactions", Details.NoOfConsignmentTransactions); cmd.Parameters.AddWithValue("NoOfConsignmentRefundTransactions", Details.NoOfConsignmentRefundTransactions); cmd.Parameters.AddWithValue("NoOfWalkInTransactions", Details.NoOfWalkInTransactions); cmd.Parameters.AddWithValue("NoOfWalkInRefundTransactions", Details.NoOfWalkInRefundTransactions); cmd.Parameters.AddWithValue("NoOfOutOfStockTransactions", Details.NoOfOutOfStockTransactions); cmd.Parameters.AddWithValue("NoOfOutOfStockRefundTransactions", Details.NoOfOutOfStockRefundTransactions); cmd.Parameters.AddWithValue("PromotionalItems", Details.PromotionalItems); cmd.Parameters.AddWithValue("CreditSalesTax", Details.CreditSalesTax); cmd.Parameters.AddWithValue("BranchID", Details.BranchID); cmd.Parameters.AddWithValue("TerminalNo", Details.TerminalNo); cmd.Parameters.AddWithValue("CashierID", Details.CashierID); cmd.CommandText = SQL; base.ExecuteNonQuery(cmd); } catch (Exception ex) { throw base.ThrowException(ex); } }
public Int32 Save(CashierReportDetails Details) { try { MySqlCommand cmd = new MySqlCommand(); cmd.CommandType = System.Data.CommandType.Text; string SQL = "CALL procSaveCashierReport(@BranchID, @TerminalNo, @SyncID, @CashierReportID, @CashierID, @TerminalID, @NetSales, @GrossSales, " + "@TotalDiscount, @SNRDiscount, @PWDDiscount, @OtherDiscount, @DailySales," + "@ItemSold, @QuantitySold, @GroupSales, @VAT, @EVAT, @LocalTax, @CashSales, @ChequeSales, @CreditCardSales," + "@CreditSales, @CreditPayment, @CashInDrawer, @TotalDisburse, @CashDisburse, @ChequeDisburse," + "@CreditCardDisburse, @TotalWithhold, @CashWithhold, @ChequeWithhold, @CreditCardWithhold," + "@TotalPaidOut, @CashPaidOut, @ChequePaidOut, @CreditCardPaidOut, @BeginningBalance," + "@VoidSales, @RefundSales, @ItemsDiscount, @SNRItemsDiscount, @PWDItemsDiscount, @OtherItemsDiscount, @SubtotalDiscount, @NoOfCashTransactions," + "@NoOfChequeTransactions, @NoOfCreditCardTransactions, @NoOfCreditTransactions, " + "@NoOfCombinationPaymentTransactions, @NoOfCreditPaymentTransactions, @NoOfClosedTransactions," + "@NoOfRefundTransactions, @NoOfVoidTransactions, @NoOfTotalTransactions, @CashCount, " + "@LastLoginDate, @TotalDeposit, @CashDeposit, @ChequeDeposit, @CreditCardDeposit, " + "@DebitPayment, @NoOfDebitPaymentTransactions, @TotalCharge, @IsCashCountInitialized," + "@NoOfDiscountedTransactions, @NegativeAdjustments, @NoOfNegativeAdjustmentTransactions," + "@PromotionalItems, @CreditSalesTax, @DebitDeposit, @RewardPointsPayment, @RewardConvertedPayment," + "@NoOfRewardPointsPayment, @CreditPaymentCash, @CreditPaymentCheque," + "@CreditPaymentCreditCard, @CreditPaymentDebit, " + "@RefundCash, @RefundCheque, @RefundCreditCard, @RefundCredit, @RefundDebit, " + "@NoOfConsignmentTransactions, @NoOfConsignmentRefundTransactions, @NoOfWalkInTransactions, " + "@NoOfWalkInRefundTransactions, @NoOfOutOfStockTransactions, @NoOfOutOfStockRefundTransactions," + "@ConsignmentSales, @ConsignmentRefundSales, @WalkInSales," + "@WalkInRefundSales, @OutOfStockSales, @OutOfStockRefundSales," + "@CreatedOn, @LastModified);"; cmd.Parameters.AddWithValue("BranchID", Details.BranchID); cmd.Parameters.AddWithValue("TerminalNo", Details.TerminalNo); cmd.Parameters.AddWithValue("SyncID", Details.SyncID); cmd.Parameters.AddWithValue("CashierReportID", Details.CashierReportID); cmd.Parameters.AddWithValue("CashierID", Details.CashierID); cmd.Parameters.AddWithValue("TerminalID", Details.TerminalID); cmd.Parameters.AddWithValue("NetSales", Details.NetSales); cmd.Parameters.AddWithValue("GrossSales", Details.GrossSales); cmd.Parameters.AddWithValue("TotalDiscount", Details.TotalDiscount); cmd.Parameters.AddWithValue("SNRDiscount", Details.SNRDiscount); cmd.Parameters.AddWithValue("PWDDiscount", Details.PWDDiscount); cmd.Parameters.AddWithValue("OtherDiscount", Details.OtherDiscount); cmd.Parameters.AddWithValue("DailySales", Details.DailySales); cmd.Parameters.AddWithValue("ItemSold", Details.ItemSold); cmd.Parameters.AddWithValue("QuantitySold", Details.QuantitySold); cmd.Parameters.AddWithValue("GroupSales", Details.GroupSales); cmd.Parameters.AddWithValue("VAT", Details.VAT); cmd.Parameters.AddWithValue("EVAT", Details.EVAT); cmd.Parameters.AddWithValue("LocalTax", Details.LocalTax); cmd.Parameters.AddWithValue("CashSales", Details.CashSales); cmd.Parameters.AddWithValue("ChequeSales", Details.ChequeSales); cmd.Parameters.AddWithValue("CreditCardSales", Details.CreditCardSales); cmd.Parameters.AddWithValue("CreditSales", Details.CreditSales); cmd.Parameters.AddWithValue("CreditPayment", Details.CreditPayment); cmd.Parameters.AddWithValue("CashInDrawer", Details.CashInDrawer); cmd.Parameters.AddWithValue("TotalDisburse", Details.TotalDisburse); cmd.Parameters.AddWithValue("CashDisburse", Details.CashDisburse); cmd.Parameters.AddWithValue("ChequeDisburse", Details.ChequeDisburse); cmd.Parameters.AddWithValue("CreditCardDisburse", Details.CreditCardDisburse); cmd.Parameters.AddWithValue("TotalWithhold", Details.TotalWithHold); cmd.Parameters.AddWithValue("CashWithhold", Details.CashWithHold); cmd.Parameters.AddWithValue("ChequeWithhold", Details.ChequeWithHold); cmd.Parameters.AddWithValue("CreditCardWithhold", Details.CreditCardWithHold); cmd.Parameters.AddWithValue("TotalPaidOut", Details.TotalPaidOut); cmd.Parameters.AddWithValue("CashPaidOut", Details.CashPaidOut); cmd.Parameters.AddWithValue("ChequePaidOut", Details.ChequePaidOut); cmd.Parameters.AddWithValue("CreditCardPaidOut", Details.CreditCardPaidOut); cmd.Parameters.AddWithValue("BeginningBalance", Details.BeginningBalance); cmd.Parameters.AddWithValue("VoidSales", Details.VoidSales); cmd.Parameters.AddWithValue("RefundSales", Details.RefundSales); cmd.Parameters.AddWithValue("ItemsDiscount", Details.ItemsDiscount); cmd.Parameters.AddWithValue("SNRItemsDiscount", Details.SNRItemsDiscount); cmd.Parameters.AddWithValue("PWDItemsDiscount", Details.PWDItemsDiscount); cmd.Parameters.AddWithValue("OtherItemsDiscount", Details.OtherItemsDiscount); cmd.Parameters.AddWithValue("SubtotalDiscount", Details.SubTotalDiscount); cmd.Parameters.AddWithValue("NoOfCashTransactions", Details.NoOfCashTransactions); cmd.Parameters.AddWithValue("NoOfChequeTransactions", Details.NoOfChequeTransactions); cmd.Parameters.AddWithValue("NoOfCreditCardTransactions", Details.NoOfCreditCardTransactions); cmd.Parameters.AddWithValue("NoOfCreditTransactions", Details.NoOfCreditTransactions); cmd.Parameters.AddWithValue("NoOfCombinationPaymentTransactions", Details.NoOfCombinationPaymentTransactions); cmd.Parameters.AddWithValue("NoOfCreditPaymentTransactions", Details.NoOfCreditPaymentTransactions); cmd.Parameters.AddWithValue("NoOfClosedTransactions", Details.NoOfClosedTransactions); cmd.Parameters.AddWithValue("NoOfRefundTransactions", Details.NoOfRefundTransactions); cmd.Parameters.AddWithValue("NoOfVoidTransactions", Details.NoOfVoidTransactions); cmd.Parameters.AddWithValue("NoOfTotalTransactions", Details.NoOfTotalTransactions); cmd.Parameters.AddWithValue("CashCount", Details.CashCount); cmd.Parameters.AddWithValue("LastLoginDate", Details.LastLoginDate); cmd.Parameters.AddWithValue("TotalDeposit", Details.TotalDeposit); cmd.Parameters.AddWithValue("CashDeposit", Details.CashDeposit); cmd.Parameters.AddWithValue("ChequeDeposit", Details.ChequeDeposit); cmd.Parameters.AddWithValue("CreditCardDeposit", Details.CreditCardDeposit); cmd.Parameters.AddWithValue("DebitPayment", Details.DebitPayment); cmd.Parameters.AddWithValue("NoOfDebitPaymentTransactions", Details.NoOfDebitPaymentTransactions); cmd.Parameters.AddWithValue("TotalCharge", Details.TotalCharge); cmd.Parameters.AddWithValue("IsCashCountInitialized", Details.IsCashCountInitialized); cmd.Parameters.AddWithValue("NoOfDiscountedTransactions", Details.NoOfDiscountedTransactions); cmd.Parameters.AddWithValue("NegativeAdjustments", Details.NegativeAdjustments); cmd.Parameters.AddWithValue("NoOfNegativeAdjustmentTransactions", Details.NoOfNegativeAdjustmentTransactions); cmd.Parameters.AddWithValue("PromotionalItems", Details.PromotionalItems); cmd.Parameters.AddWithValue("CreditSalesTax", Details.CreditSalesTax); cmd.Parameters.AddWithValue("DebitDeposit", Details.DebitDeposit); cmd.Parameters.AddWithValue("RewardPointsPayment", Details.RewardPointsPayment); cmd.Parameters.AddWithValue("RewardConvertedPayment", Details.RewardConvertedPayment); cmd.Parameters.AddWithValue("NoOfRewardPointsPayment", Details.NoOfRewardPointsPayment); cmd.Parameters.AddWithValue("CreditPaymentCash", Details.CreditPaymentCash); cmd.Parameters.AddWithValue("CreditPaymentCheque", Details.CreditPaymentCheque); cmd.Parameters.AddWithValue("CreditPaymentCreditCard", Details.CreditPaymentCreditCard); cmd.Parameters.AddWithValue("CreditPaymentDebit", Details.CreditPaymentDebit); cmd.Parameters.AddWithValue("RefundCash", Details.RefundCash); cmd.Parameters.AddWithValue("RefundCheque", Details.RefundCheque); cmd.Parameters.AddWithValue("RefundCreditCard", Details.RefundCreditCard); cmd.Parameters.AddWithValue("RefundCredit", Details.RefundCredit); cmd.Parameters.AddWithValue("RefundDebit", Details.RefundDebit); cmd.Parameters.AddWithValue("NoOfConsignmentTransactions", Details.NoOfConsignmentTransactions); cmd.Parameters.AddWithValue("NoOfConsignmentRefundTransactions", Details.NoOfConsignmentRefundTransactions); cmd.Parameters.AddWithValue("NoOfWalkInTransactions", Details.NoOfWalkInTransactions); cmd.Parameters.AddWithValue("NoOfWalkInRefundTransactions", Details.NoOfWalkInRefundTransactions); cmd.Parameters.AddWithValue("NoOfOutOfStockTransactions", Details.NoOfOutOfStockTransactions); cmd.Parameters.AddWithValue("NoOfOutOfStockRefundTransactions", Details.NoOfOutOfStockRefundTransactions); cmd.Parameters.AddWithValue("ConsignmentSales", Details.ConsignmentSales); cmd.Parameters.AddWithValue("ConsignmentRefundSales", Details.ConsignmentRefundSales); cmd.Parameters.AddWithValue("WalkInSales", Details.WalkInSales); cmd.Parameters.AddWithValue("WalkInRefundSales", Details.WalkInRefundSales); cmd.Parameters.AddWithValue("OutOfStockSales", Details.OutOfStockSales); cmd.Parameters.AddWithValue("OutOfStockRefundSales", Details.OutOfStockRefundSales); cmd.Parameters.AddWithValue("CreatedOn", Details.CreatedOn == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.CreatedOn); cmd.Parameters.AddWithValue("LastModified", Details.LastModified == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.LastModified); cmd.CommandText = SQL; return base.ExecuteNonQuery(cmd); } catch (Exception ex) { throw base.ThrowException(ex); } }
public static CashierReportDetails SetDetails(System.Data.DataTable dt) { CashierReportDetails Details = new CashierReportDetails(); foreach (System.Data.DataRow dr in dt.Rows) { Details.BranchID = Int32.Parse(dr["BranchID"].ToString()); Details.TerminalNo = dr["TerminalNo"].ToString(); Details.CashierID = Int64.Parse(dr["CashierID"].ToString()); Details.NetSales = decimal.Parse(dr["NetSales"].ToString()); Details.GrossSales = decimal.Parse(dr["GrossSales"].ToString()); Details.TotalDiscount = decimal.Parse(dr["TotalDiscount"].ToString()); Details.SNRDiscount = decimal.Parse(dr["SNRDiscount"].ToString()); Details.PWDDiscount = decimal.Parse(dr["PWDDiscount"].ToString()); Details.OtherDiscount = decimal.Parse(dr["OtherDiscount"].ToString()); Details.TotalCharge = decimal.Parse(dr["TotalCharge"].ToString()); Details.DailySales = decimal.Parse(dr["DailySales"].ToString()); Details.ItemSold = decimal.Parse(dr["ItemSold"].ToString()); Details.QuantitySold = decimal.Parse(dr["QuantitySold"].ToString()); Details.GroupSales = decimal.Parse(dr["GroupSales"].ToString()); Details.VATExempt = decimal.Parse(dr["VATExempt"].ToString()); Details.NonVATableAmount = decimal.Parse(dr["NonVATableAmount"].ToString()); Details.VAT = decimal.Parse(dr["VAT"].ToString()); Details.VATableAmount = decimal.Parse(dr["VATableAmount"].ToString()); Details.ZeroRatedSales = decimal.Parse(dr["ZeroRatedSales"].ToString()); Details.LocalTax = decimal.Parse(dr["LocalTax"].ToString()); Details.CashSales = decimal.Parse(dr["CashSales"].ToString()); Details.ChequeSales = decimal.Parse(dr["ChequeSales"].ToString()); Details.CreditCardSales = decimal.Parse(dr["CreditCardSales"].ToString()); Details.CreditSales = decimal.Parse(dr["CreditSales"].ToString()); Details.RefundCash = decimal.Parse(dr["RefundCash"].ToString()); Details.RefundCheque = decimal.Parse(dr["RefundCheque"].ToString()); Details.RefundCreditCard = decimal.Parse(dr["RefundCreditCard"].ToString()); Details.RefundCredit = decimal.Parse(dr["RefundCredit"].ToString()); Details.RefundDebit = decimal.Parse(dr["RefundDebit"].ToString()); Details.CreditPayment = decimal.Parse(dr["CreditPayment"].ToString()); Details.CreditPaymentCash = decimal.Parse(dr["CreditPaymentCash"].ToString()); Details.CreditPaymentCheque = decimal.Parse(dr["CreditPaymentCheque"].ToString()); Details.CreditPaymentCreditCard = decimal.Parse(dr["CreditPaymentCreditCard"].ToString()); Details.CreditPaymentDebit = decimal.Parse(dr["CreditPaymentDebit"].ToString()); Details.DebitPayment = decimal.Parse(dr["DebitPayment"].ToString()); Details.RewardPointsPayment = decimal.Parse(dr["RewardPointsPayment"].ToString()); Details.RewardConvertedPayment = decimal.Parse(dr["RewardConvertedPayment"].ToString()); Details.CashInDrawer = decimal.Parse(dr["CashInDrawer"].ToString()); Details.TotalDisburse = decimal.Parse(dr["TotalDisburse"].ToString()); Details.CashDisburse = decimal.Parse(dr["CashDisburse"].ToString()); Details.ChequeDisburse = decimal.Parse(dr["ChequeDisburse"].ToString()); Details.CreditCardDisburse = decimal.Parse(dr["CreditCardDisburse"].ToString()); Details.TotalWithHold = decimal.Parse(dr["TotalWithHold"].ToString()); Details.CashWithHold = decimal.Parse(dr["CashWithHold"].ToString()); Details.ChequeWithHold = decimal.Parse(dr["ChequeWithHold"].ToString()); Details.CreditCardWithHold = decimal.Parse(dr["CreditCardWithHold"].ToString()); Details.TotalPaidOut = decimal.Parse(dr["TotalPaidOut"].ToString()); Details.TotalDeposit = decimal.Parse(dr["TotalDeposit"].ToString()); Details.CashDeposit = decimal.Parse(dr["CashDeposit"].ToString()); Details.ChequeDeposit = decimal.Parse(dr["ChequeDeposit"].ToString()); Details.CreditCardDeposit = decimal.Parse(dr["CreditCardDeposit"].ToString()); Details.BeginningBalance = decimal.Parse(dr["BeginningBalance"].ToString()); Details.VoidSales = decimal.Parse(dr["VoidSales"].ToString()); Details.RefundSales = decimal.Parse(dr["RefundSales"].ToString()); Details.ItemsDiscount = decimal.Parse(dr["ItemsDiscount"].ToString()); Details.SNRItemsDiscount = decimal.Parse(dr["SNRItemsDiscount"].ToString()); Details.PWDItemsDiscount = decimal.Parse(dr["PWDItemsDiscount"].ToString()); Details.OtherItemsDiscount = decimal.Parse(dr["OtherItemsDiscount"].ToString()); Details.SubTotalDiscount = decimal.Parse(dr["SubTotalDiscount"].ToString()); Details.NoOfCashTransactions = Int32.Parse(dr["NoOfCashTransactions"].ToString()); Details.NoOfChequeTransactions = Int32.Parse(dr["NoOfChequeTransactions"].ToString()); Details.NoOfCreditCardTransactions = Int32.Parse(dr["NoOfCreditCardTransactions"].ToString()); Details.NoOfCreditTransactions = Int32.Parse(dr["NoOfCreditTransactions"].ToString()); Details.NoOfCombinationPaymentTransactions = Int32.Parse(dr["NoOfCombinationPaymentTransactions"].ToString()); Details.NoOfCreditPaymentTransactions = Int32.Parse(dr["NoOfCreditPaymentTransactions"].ToString()); Details.NoOfDebitPaymentTransactions = Int32.Parse(dr["NoOfDebitPaymentTransactions"].ToString()); Details.NoOfClosedTransactions = Int32.Parse(dr["NoOfTotalTransactions"].ToString()); Details.NoOfRefundTransactions = Int32.Parse(dr["NoOfRefundTransactions"].ToString()); Details.NoOfVoidTransactions = Int32.Parse(dr["NoOfVoidTransactions"].ToString()); Details.NoOfRewardPointsPayment = Int32.Parse(dr["NoOfRewardPointsPayment"].ToString()); Details.NoOfTotalTransactions = Int32.Parse(dr["NoOfTotalTransactions"].ToString()); Details.NoOfConsignmentTransactions = Int32.Parse(dr["NoOfConsignmentTransactions"].ToString()); Details.NoOfConsignmentRefundTransactions = Int32.Parse(dr["NoOfConsignmentRefundTransactions"].ToString()); Details.NoOfWalkInTransactions = Int32.Parse(dr["NoOfWalkInTransactions"].ToString()); Details.NoOfWalkInRefundTransactions = Int32.Parse(dr["NoOfWalkInRefundTransactions"].ToString()); Details.NoOfOutOfStockTransactions = Int32.Parse(dr["NoOfOutOfStockTransactions"].ToString()); Details.NoOfOutOfStockRefundTransactions = Int32.Parse(dr["NoOfOutOfStockRefundTransactions"].ToString()); Details.ConsignmentSales = decimal.Parse(dr["ConsignmentSales"].ToString()); Details.ConsignmentRefundSales = decimal.Parse(dr["ConsignmentRefundSales"].ToString()); Details.WalkInSales = decimal.Parse(dr["WalkInSales"].ToString()); Details.WalkInRefundSales = decimal.Parse(dr["WalkInRefundSales"].ToString()); Details.OutOfStockSales = decimal.Parse(dr["OutOfStockSales"].ToString()); Details.OutOfStockRefundSales = decimal.Parse(dr["OutOfStockRefundSales"].ToString()); Details.CashCount = decimal.Parse(dr["CashCount"].ToString()); Details.LastLoginDate = DateTime.Parse(dr["LastLoginDate"].ToString()); } return Details; }