public JsonResult SaveVoucher(VoucherTransaction objCashBankVoucher, List <VoucherTransaction> lstOtherVoucher, string voucherType, List <SubLedgerHeadDetails> lstSubLedgerHeadDetails) { try { objLoginHelper = (LoginHelper)Session["LogInInformation"]; string EntrySource = string.Empty; if (voucherType == "C") { EntrySource = Helper.ContraVoucherForAccountsEntrySource; } else if (voucherType == "N") { EntrySource = Helper.NonCashVoucherForAccountsEntrySource; } else if (voucherType == "P") { EntrySource = Helper.PaymentVoucherForAccountsEntrySource; } else if (voucherType == "R") { EntrySource = Helper.ReceiveVoucherForAccountsEntrySource; } ArrayList transactionNumberMax = accountDeptDal.ReadVoucherTransNoMax(objLoginHelper.LocationCode, objLoginHelper.CurrentDate.ToString("yyMMdd")); objCashBankVoucher.TransactionNo = Helper.AccountSequenceNumberGeneration(transactionNumberMax, objLoginHelper); Acc_TransNoCount objAccTransNocount = new Acc_TransNoCount(); objAccTransNocount = voucherProcess.TransNoCount(objCashBankVoucher, objLoginHelper.LocationCode); objAccTransNocount.TransCount = null; Acc_PrePostTransMaster objPrePostTransMaster = new Acc_PrePostTransMaster(); objPrePostTransMaster = voucherProcess.CashBankVoucherProcess(objCashBankVoucher, voucherType, objLoginHelper, EntrySource); objPrePostTransMaster.IsAutoEntry = false; List <Acc_PrePostTransDetail> lstPrePostTransDetail = new List <Acc_PrePostTransDetail>(); lstPrePostTransDetail = voucherProcess.OtherBankVoucherProcess(lstOtherVoucher, voucherType, objLoginHelper, EntrySource, objCashBankVoucher.TransactionNo); List <Acc_PrePostTransDetailByDimension> lstPrePostTransDetailByDimension = new List <Acc_PrePostTransDetailByDimension>(); if (lstSubLedgerHeadDetails != null) { lstPrePostTransDetailByDimension = voucherProcess.PrePostTransDetailByDimensionProcess(objCashBankVoucher, lstPrePostTransDetail, lstSubLedgerHeadDetails, objLoginHelper.LocationCode); } objPrePostTransMaster = accountDeptDal.CreateVoucher(objAccTransNocount, objPrePostTransMaster, lstPrePostTransDetail, lstPrePostTransDetailByDimension); return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(string.Empty, Helper.AccountSequenceNumberGeneration(objPrePostTransMaster.TransNo)) }); } catch (Exception ex) { return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(ex) }); } }
public JsonResult SaveEmployeeWiseSalaryPayment(VoucherTransaction objCashBankVoucher, List <VoucherTransaction> lstOtherVoucher, List <EmployeeWiseSalaryPayment> lstEmployeeWiseSalary, string voucherType) { try { objLoginHelper = (LoginHelper)Session["LogInInformation"]; string EntrySource = string.Empty; EntrySource = Helper.BankPaymentVoucherForAccountsEntrySource; ArrayList transactionNumberMax = accountDeptDal.ReadVoucherTransNoMax(objLoginHelper.LocationCode, objLoginHelper.CurrentDate.ToString("yyMMdd")); objCashBankVoucher.TransactionNo = Helper.AccountSequenceNumberGeneration(transactionNumberMax, objLoginHelper); Acc_TransNoCount objAccTransNocount = new Acc_TransNoCount(); objAccTransNocount = voucherProcess.TransNoCount(objCashBankVoucher, objLoginHelper.LocationCode); objAccTransNocount.TransCount = null; Acc_PrePostTransMaster objPrePostTransMaster = new Acc_PrePostTransMaster(); objPrePostTransMaster = voucherProcess.CashBankVoucherProcess(objCashBankVoucher, voucherType, objLoginHelper, EntrySource); objPrePostTransMaster.IsAutoEntry = false; List <Acc_PrePostTransDetail> lstPrePostTransDetail = new List <Acc_PrePostTransDetail>(); lstPrePostTransDetail = voucherProcess.OtherBankVoucherProcess(lstOtherVoucher, voucherType, objLoginHelper, EntrySource, objCashBankVoucher.TransactionNo); List <SubLedgerHeadDetails> lstSubLedgerHeadDetails = new List <SubLedgerHeadDetails>(); lstSubLedgerHeadDetails = voucherProcess.PrepareEmployeeWiseSalaryToSubLedgerDimension(lstEmployeeWiseSalary, objLoginHelper.LocationCode, objCashBankVoucher.TransactionNo); List <Acc_PrePostTransDetailByDimension> lstTransDetailByDimension = new List <Acc_PrePostTransDetailByDimension>(); lstTransDetailByDimension = voucherProcess.PrePostTransDetailByDimensionProcess(objCashBankVoucher, lstPrePostTransDetail, lstSubLedgerHeadDetails, objLoginHelper.LocationCode); //start oroginal //objPrePostTransMaster = accountDeptDal.CreateVoucher(objPrePostTransMaster, lstEmployeeWiseSalary); // objPrePostTransMaster = accountDeptDal.CreateVoucher(objAccTransNocount, objPrePostTransMaster, lstPrePostTransDetail, lstTransDetailByDimension); //end oroginal //start new string supportMethod = "ttd";//its use for support method objPrePostTransMaster = accountDeptDal.CreateVoucherForSaveEmployeeWiseSalaryPayment(objAccTransNocount, lstEmployeeWiseSalary, lstPrePostTransDetail, lstTransDetailByDimension, objPrePostTransMaster, supportMethod); //end new return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(string.Empty, Helper.AccountSequenceNumberGeneration(objPrePostTransMaster.TransNo)) }); } catch (Exception ex) { return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(ex) }); } }
public Acc_TransNoCount TransNoCount(VoucherTransaction objCashBankVoucher, string locationCode) { Acc_TransNoCount objtransNoCount = new Acc_TransNoCount(); objtransNoCount.LocationCode = locationCode; objtransNoCount.TransDate = DateTime.Now; //Convert.ToDateTime(objCashBankVoucher.TransactionDate); //objtransNoCount.ProjectCode = objCashBankVoucher.ProjectCode; objtransNoCount.TransNo = objCashBankVoucher.TransactionNo; //objtransNoCount.Add(objtransNoCount); return(objtransNoCount); }
public JsonResult SavePaymentOrReceieveVoucherForAuditor(VoucherTransaction objCashBankVoucher, List <VoucherTransaction> lstOtherVoucher, VoucherTransactionAudit objvoucherTransactionAudit, string voucherType) { try { objLoginHelper = (LoginHelper)Session["LogInInformation"]; string EntrySource = string.Empty; if (voucherType == "C") { EntrySource = Helper.ContraVoucherForAuditorEntrySource; } else if (voucherType == "N") { EntrySource = Helper.NonCashVoucherForAuditorEntrySource; } else if (voucherType == "P") { EntrySource = Helper.PaymentVoucherForAuditorEntrySource; } else if (voucherType == "R") { EntrySource = Helper.ReceiveVoucherForAuditorEntrySource; } Acc_TransNoCount objAccTransNocount = new Acc_TransNoCount(); objAccTransNocount = voucherProcess.TransNoCount(objCashBankVoucher, objLoginHelper.LocationCode); //Newly Add By Md.Sultan Mahmud objAccTransNocount.TransCount = null; Acc_PrePostTransMaster objPrePostTransMaster = new Acc_PrePostTransMaster(); objPrePostTransMaster = voucherProcess.CashBankVoucherProcess(objCashBankVoucher, voucherType, objLoginHelper, EntrySource); List <Acc_PrePostTransDetail> lstPrePostTransDetail = new List <Acc_PrePostTransDetail>(); lstPrePostTransDetail = voucherProcess.OtherBankVoucherProcess(lstOtherVoucher, voucherType, objLoginHelper, EntrySource, objCashBankVoucher.TransactionNo); Aud_AuditAdjustmentRelatedAccountingTransaction objAuditAdjustmentRelatedAccountingTransaction = new Aud_AuditAdjustmentRelatedAccountingTransaction(); objAuditAdjustmentRelatedAccountingTransaction = voucherProcess.AuditAdjustmentVoucherOrAccount(objvoucherTransactionAudit, objLoginHelper); objPrePostTransMaster = accountDeptDal.CreateVoucher(objAccTransNocount, objPrePostTransMaster, lstPrePostTransDetail, objAuditAdjustmentRelatedAccountingTransaction); return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(string.Empty, Helper.AccountSequenceNumberGeneration(objPrePostTransMaster.TransNo)) }); } catch (Exception ex) { return(new JsonResult { Data = ExceptionHelper.ExceptionMessage(ex) }); } }
public Acc_PrePostTransMaster CreateVoucher(Acc_TransNoCount objAccTransNocount, Acc_PrePostTransMaster objPrePostTransMaster, List <Acc_PrePostTransDetail> lstPrePostTransDetail, Aud_AuditAdjustmentRelatedAccountingTransaction objAuditAdjustmentRelatedAccountingTransaction, List <Acc_PrePostTransDetailByDimension> lstPrePostTransDetailByDimension) { return(AMSService.Create(objAccTransNocount, objPrePostTransMaster, lstPrePostTransDetail, objAuditAdjustmentRelatedAccountingTransaction, lstPrePostTransDetailByDimension)); }
public Acc_PrePostTransMaster CreateVoucherForSaveEmployeeWiseSalaryPayment(Acc_TransNoCount objAccTransNocount, List <EmployeeWiseSalaryPayment> lstEmployeeWiseSalary, List <Acc_PrePostTransDetail> lstPrePostTransDetail, List <Acc_PrePostTransDetailByDimension> lstPrePostTransDetailByDimension, Acc_PrePostTransMaster objPrePostTransMaster, string supportMethod) { return(AMSService.Create(objAccTransNocount, lstEmployeeWiseSalary, lstPrePostTransDetail, lstPrePostTransDetailByDimension, objPrePostTransMaster, supportMethod)); }
public Acc_PrePostTransMaster CreateVoucher(Acc_TransNoCount objAccTransNocount, Acc_PrePostTransMaster objPrePostTransMaster, List <Acc_PrePostTransDetail> lstPrePostTransDetail, List <Acc_PrePostTransDetailByDimension> lstPrePostTransDetailByDimension) { return(AMSService.Create(objAccTransNocount, objPrePostTransMaster, lstPrePostTransDetail, lstPrePostTransDetailByDimension)); }