// GET: PurchaseReturn public ActionResult PurchaseReturn(string errMsg) { if (Session["UserID"] != null) { DateTime datetime = DateTime.Now; ViewBag.GLProvition = Counter("PR"); ViewBag.GLEntries = CountEntries("PR", datetime); ViewBag.LocCode = new SelectList(_locationService.All().Where(s => s.LocCode != "900").ToList(), "LocCode", "LocName"); ViewBag.CustCode = new SelectList(_subsidiaryInfoService.All().ToList().Where(x => x.SubType == "2").OrderBy(x => x.SubName), "SubCode", "SubName"); ViewBag.ItemCode = LoadDropDown.LoadEmpDlList(); var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MaintJob = sysSet.MaintJob; Session["MaintLot"] = sysSet.MaintLot; ViewBag.MaintVAT = sysSet.MaintVAT; Session["MaintVAT"] = sysSet.MaintVAT; ViewBag.Reason = LoadDropDown.LoadAdjReason(); ViewBag.ApprBy = new SelectList(_EmployeeService.All().ToList(), "Id", "UserName"); ViewBag.JobNo = LoadDropDown.LoadJobInfo(); var VchrConv = _vchrSetService.All().ToList().FirstOrDefault().VchrConv; Session["VchrConv"] = VchrConv; ViewBag.PurRetNo = LoadDropDown.GeneratePurRetNo(_PurRetMainService, "", Session["BranchCode"].ToString(), "", Session["VchrConv"].ToString()); ViewBag.errMsg = errMsg; return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
// GET: CashMoneyReceipt public ActionResult CashMoneyReceipt(string errMsg) { if (Session["UserID"] != null) { ViewBag.ProjCode = new SelectList(_ProjInfoService.All().ToList(), "ProjCode", "ProjName"); ViewBag.BranchCode = new SelectList(_branchService.All().ToList(), "BranchCode", "BranchName"); ViewBag.MRAgainst = LoadDropDown.LoadMRAgainstDDL(); ViewBag.CustCode = new SelectList(_subsidiaryInfoService.All().ToList().Where(x => x.SubType == "1"), "SubCode", "SubName"); var VchrConv = _vchrSetService.All().ToList().FirstOrDefault().VchrConv; Session["VchrConv"] = VchrConv; ViewBag.MRSL = LoadDropDown.GenerateRecvSlNo(_moneyReceiptService, "", Session["BranchCode"].ToString(), "", Session["VchrConv"].ToString()); DateTime datetime = DateTime.Now; ViewBag.GLProvition = Counter("CR"); ViewBag.GLEntries = CountEntries("CR", datetime); var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MaintJob = sysSet.MaintJob; ViewBag.JobNo = LoadDropDown.LoadJobInfo(); ViewBag.errMsg = errMsg; return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
public ActionResult ChequeReceipts(string errMsg) { if (Session["UserID"] != null) { ViewBag.BranchCode = new SelectList(_branchService.All().ToList(), "BranchCode", "BranchName"); ViewBag.Accode = LoadDropDown.LoadMRAgainstDDL(); ViewBag.SubCode = new SelectList(_subsidiaryService.All().Where(x => x.SubType == "1").ToList(), "SubCode", "SubName");//LoadDropDown.LoadSubsidiaryByPurpuse("", _subsidiaryService, _subsidiaryCtrlService); ViewBag.BankCode = new SelectList(_bankInfoService.All().ToList(), "BankCode", "BankName"); ViewBag.DepositBank = LoadDropDown.LoadDepositBankDDL(); ViewBag.UpdateBy = new SelectList(_employeeInfoService.All().ToList(), "Id", "UserName"); DateTime datetime = DateTime.Now; ViewBag.GLProvition = Counter("BR"); ViewBag.GLEntries = CountEntries("BR", datetime); var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MaintJob = sysSet.MaintJob; ViewBag.JobNo = LoadDropDown.LoadJobInfo(); var VchrConv = _vchrSetService.All().ToList().FirstOrDefault().VchrConv; Session["VchrConv"] = VchrConv; ViewBag.errMsg = errMsg; return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
// GET: OnlineMoneyReceipt public ActionResult OnlineMoneyReceipt() { if (Session["UserID"] != null) { ViewBag.BranchCode = new SelectList(_branchService.All().ToList(), "BranchCode", "BranchName"); ViewBag.MRAgainst = LoadDropDown.LoadMRAgainstDDL(); ViewBag.CustCode = new SelectList(_subsidiaryInfoService.All().Where(x => x.SubType == "1").ToList(), "SubCode", "SubName"); ViewBag.bankCode = new SelectList(_bankInfoService.All().ToList(), "BankCode", "BankName"); ViewBag.DepositBank = LoadDropDown.LoadDepositBankDDL(); ViewBag.CollectedBy = new SelectList(_employeeInfoService.All().ToList(), "Id", "UserName"); var CashAc = _defACService.All().ToList().FirstOrDefault().CashAc; ViewBag.Accode = LoadDropDown.LoadGLAc(CashAc, _newChartService); DateTime datetime = DateTime.Now; ViewBag.GLProvition = Counter("BR"); ViewBag.GLEntries = CountEntries("BR", datetime); var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MaintJob = sysSet.MaintJob; ViewBag.JobNo = LoadDropDown.LoadJobInfo(); ViewBag.GetwayId = LoadDropDown.LoadGetwayProvider(); var VchrConv = _vchrSetService.All().ToList().FirstOrDefault().VchrConv; Session["VchrConv"] = VchrConv; return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
// GET: JobWiseRecPay public ActionResult JobWiseRecPay(string errMsg) { if (Session["UserID"] != null) { ViewBag.ProjCode = new SelectList(_ProjInfoService.All().ToList(), "ProjCode", "ProjName"); ViewBag.BranchCode = new SelectList(_BranchService.All().ToList(), "BranchCode", "BranchName"); //ViewBag.FYDD = new SelectList(_FYDDService.All().ToList(), "FinYear", "FinYear"); ViewBag.JobNo = LoadDropDown.LoadJobInfo(); var Fydd = _FYDDService.All().FirstOrDefault(s => s.FinYear == Session["FinYear"].ToString()); ViewBag.FyddFDate = Fydd.FYDF; ViewBag.FyddTDate = Fydd.FYDT; ViewBag.Message = errMsg; return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
// GET: CustAdjustment public ActionResult CustAdjustment() { if (Session["UserID"] != null) { DateTime datetime = DateTime.Now; ViewBag.GLProvition = Counter("JB"); ViewBag.GLEntries = CountEntries("JB", datetime); var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MaintJob = sysSet.MaintJob; ViewBag.CustCode = new SelectList(_subsidiaryInfoService.All().ToList().Where(x => x.SubType == "1").OrderBy(x => x.SubName), "SubCode", "SubName"); ViewBag.InvNo = LoadDropDown.LoadEmpDlList(); ViewBag.AdjReason = LoadDropDown.LoadAdjReason(); ViewBag.ApprBy = new SelectList(_EmployeeService.All().ToList(), "Id", "UserName"); ViewBag.JobNo = LoadDropDown.LoadJobInfo(); var VchrConv = _vchrSetService.All().ToList().FirstOrDefault().VchrConv; Session["VchrConv"] = VchrConv; ViewBag.AdjNo = LoadDropDown.GenerateAdjustmentNo(_custAdjustmentService, "", Session["BranchCode"].ToString(), "", Session["VchrConv"].ToString()); return(View()); } else { return(RedirectToAction("SecUserLogin", "SecUserLogin")); } }
public ActionResult BankOperation(BankOperation bankOperation, string errMsg) { if (bankOperation.bankAccode == null) { bankOperation.bankAccode = Session["BankAccode"].ToString(); var bankInfo = _newChartService.All().ToList().FirstOrDefault(x => x.Accode == bankOperation.bankAccode); ViewBag.bankAccode = bankInfo.AcName; Session["BankAccode"] = bankInfo.Accode; } else { var bankInfo = _newChartService.All().ToList().FirstOrDefault(x => x.Accode == bankOperation.bankAccode); ViewBag.bankAccode = bankInfo.AcName; Session["BankAccode"] = bankInfo.Accode; } List <NewChart> charts = _newChartService.All().ToList().Where(x => x.Accode.Substring(0, 1) == "1" || x.Accode.Substring(0, 1) == "3" || x.Accode.Substring(0, 1) == "2").ToList(); // List<NewChart> charts = _newChartService.All().ToList().Where(x => x.Accode.Substring(0, 1) == "3").ToList(); List <NewChart> finalList = new List <NewChart>(); foreach (var chart in charts) { bool key = true; foreach (var temp in charts) { if (chart == temp) { } else { if (chart.Accode == temp.ParentAcCode) { key = false; } } } if (key) { finalList.Add(chart); } } ViewBag.brPurAccode = new SelectList(finalList, "Accode", "AcName"); List <NewChart> echarts = _newChartService.All().ToList().Where(x => x.Accode.Substring(0, 1) == "1" || x.Accode.Substring(0, 1) == "2" || x.Accode.Substring(0, 1) == "4").ToList(); List <NewChart> efinalList = new List <NewChart>(); foreach (var chart in echarts) { bool key = true; foreach (var temp in echarts) { if (chart == temp) { } else { if (chart.Accode == temp.ParentAcCode) { key = false; } } } if (key) { efinalList.Add(chart); } } ViewBag.purAccode = new SelectList(efinalList, "Accode", "AcName"); ViewBag.SubCode = new SelectList(_subsidiaryService.All().ToList(), "SubCode", "SubName"); ViewBag.bankCode = new SelectList(_BankInfoService.All().ToList(), "BankCode", "BankName"); DateTime datetime = DateTime.Now; ViewBag.Date = datetime.ToString("dd/MM/yyyy"); string branchCode = Session["BranchCode"].ToString(); string bankAccode = Session["BankAccode"].ToString(); //ViewBag.OpenBal = GetOpenBal(DateTime.Now, bankAccode); ViewBag.OpenBal = GetOpenBal(datetime); ViewBag.GLProvition = Counter("BOR", "PV"); ViewBag.GLEntries = CountVoucherMain("BOR", "MV", datetime); ViewBag.GLProvitionB = Counter("BOP", "PV"); ViewBag.GLEntriesB = CountVoucherMain("BOP", "MV", datetime); var bank = new List <BankOperationVModel>(); bank = GetAllRemittances(datetime, branchCode, bankAccode); GetAllPayment(datetime, branchCode, bankAccode).ForEach(x => bank.Add(x)); ViewBag.Items = bank; ViewBag.JobNo = LoadDropDown.LoadJobInfo(); //By Farhad For Remittance button/popup will be show/hide. var sysSet = _sysSetService.All().ToList().FirstOrDefault(); ViewBag.MrConv = sysSet.MRConv; ViewBag.MaintJob = sysSet.MaintJob; Session["MaintLot"] = sysSet.MaintLot; ViewBag.MaintLot = sysSet.MaintLot; ViewBag.HasRemittance = sysSet.HasRemittance; ViewBag.IsSubsidiaryCtrl = sysSet.IsSubsidiaryCtrl; if (sysSet.IsSubsidiaryCtrl == true) { ViewBag.brSubCode = LoadDropDown.LoadSubsidiaryByPurpuse("", _subsidiaryService, _subsidiaryCtrlService); } else { ViewBag.brSubCode = LoadDropDown.LoadSubsidiary(_subsidiaryService); } ViewBag.errMsg = errMsg; //For us Culture Ex: 0.00 const string culture = "en-US"; CultureInfo ci = CultureInfo.GetCultureInfo(culture); Thread.CurrentThread.CurrentCulture = ci; Thread.CurrentThread.CurrentUICulture = ci; return(View()); }