public ActionResult LocationSelection() { LoginHelper objLoginHelper = new LoginHelper(); objLoginHelper = (LoginHelper)Session["LogInInformation"]; ViewBag.LocationTitle = objLoginHelper.LocationTitle; ViewBag.Location = objLoginHelper.Location; ViewBag.ZoneTitle = objLoginHelper.ZoneTitle; ViewBag.ZoneName = objLoginHelper.LogInForZoneName; ViewBag.RegionTitle = objLoginHelper.RegionTitle; ViewBag.RegionName = objLoginHelper.LogInForRegionName; ViewBag.UnitTitle = objLoginHelper.UnitTitle; ViewBag.UnitName = objLoginHelper.LogInForUnitName; if (objLoginHelper.UerRoleOrGroupID == UserGroup.RegionManager) { ViewBag.URL = "HeadOffice/Auditor"; ViewBag.RoleOrGroup = UserGroup.HeadOfficeAudit; } else { ViewBag.URL = objLoginHelper.URL; ViewBag.RoleOrGroup = objLoginHelper.UerRoleOrGroupID; } ViewBag.LocationType = new UserLocationType().UserLocationTypeFormat().Where(l => l.LocationTypeID != "region").ToList(); ViewBag.Zone = erpDal.Zone(); ViewBag.ModuleName = "Auditor Module"; ViewBag.TopMenu = objLoginHelper.TopMenu; return(View()); }
public ActionResult EmployeeSearch() { objLoginHelper = (LoginHelper)Session["LogInInformation"]; if (!securityDal.IsPageAccessible(Helper.ForHRMS, "EmployeeSearch", objLoginHelper.UerRoleOrGroupID, Helper.Inactive, out message)) { Session["messageInformation"] = message; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } ViewBag.Designation = hrmsData.ReadEmployeeDesignation(); ViewBag.LocationTitle = objLoginHelper.LocationTitle; ViewBag.Location = objLoginHelper.Location; ViewBag.ZoneTitle = objLoginHelper.ZoneTitle; ViewBag.ZoneName = objLoginHelper.LogInForZoneName; ViewBag.RegionTitle = objLoginHelper.RegionTitle; ViewBag.RegionName = objLoginHelper.LogInForRegionName; ViewBag.UnitTitle = objLoginHelper.UnitTitle; ViewBag.UnitName = objLoginHelper.LogInForUnitName; ViewBag.OpenMonthYear = "Month: " + objLoginHelper.MonthOpenForHRMS.ToString("MMMM-yy"); ViewBag.ModuleName = objLoginHelper.ModluleTitle; ViewBag.TopMenu = objLoginHelper.TopMenu; ViewBag.CurrentDay = objLoginHelper.MonthOpenForHRMS.Date.ToString("dd-MMM-yyyy"); ViewBag.CalenderDate = objLoginHelper.MonthOpenForHRMS; ViewBag.Zone = erpDal.Zone(); // Need To Change After Riview return(View()); }
public ActionResult SummarySheetForRegionalSalesPosting() { objLoginHelper = (LoginHelper)Session["LogInInformation"]; if (!securityDal.IsPageAccessible(Helper.ForSales, "SummarySheetForRegionalSalesPosting", objLoginHelper.UerRoleOrGroupID, Helper.Inactive, out message)) { Session["messageInformation"] = message; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } ViewBag.LocationTitle = objLoginHelper.LocationTitle; ViewBag.Location = objLoginHelper.Location; ViewBag.ZoneTitle = objLoginHelper.ZoneTitle; ViewBag.ZoneName = objLoginHelper.LogInForZoneName; ViewBag.RegionTitle = objLoginHelper.RegionTitle; ViewBag.RegionName = objLoginHelper.LogInForRegionName; ViewBag.UnitTitle = objLoginHelper.UnitTitle; ViewBag.UnitName = objLoginHelper.LogInForUnitName; ViewBag.OpenMonthYear = "Month: " + objLoginHelper.MonthOpenForSales.ToString("MMMM-yy"); ViewBag.ModuleName = objLoginHelper.ModluleTitle; ViewBag.TopMenu = objLoginHelper.TopMenu; ViewBag.YearMonth = new YearMonthFormat().MonthFormat(); ViewBag.Zone = erpDal.Zone(); return(View()); }
public ActionResult EmployeeRegister() { objLoginHelper = (LoginHelper)Session["LogInInformation"]; if (!securityDal.IsPageAccessible(Helper.ForHRMS, "EmployeeRegister", objLoginHelper.UerRoleOrGroupID, Helper.Inactive, out message)) { Session["messageInformation"] = message; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } if (objLoginHelper.TransactionOpenDate == Helper.InvalidDate()) { Session["messageInformation"] = "Day Is Not Open"; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } ViewBag.LocationTitle = objLoginHelper.LocationTitle; ViewBag.Location = objLoginHelper.Location; ViewBag.ZoneTitle = objLoginHelper.ZoneTitle; ViewBag.ZoneName = objLoginHelper.LogInForZoneName; ViewBag.RegionTitle = objLoginHelper.RegionTitle; ViewBag.RegionName = objLoginHelper.LogInForRegionName; ViewBag.UnitTitle = objLoginHelper.UnitTitle; ViewBag.UnitName = objLoginHelper.LogInForUnitName; ViewBag.OpenMonthYear = "Month: " + objLoginHelper.TransactionOpenDate.ToString("MMMM-yy"); ViewBag.ModuleName = objLoginHelper.ModluleTitle; ViewBag.TopMenu = objLoginHelper.TopMenu; ViewBag.CurrentDay = objLoginHelper.TransactionOpenDate.Date.ToString("dd-MMM-yyyy"); ViewBag.CalenderDate = objLoginHelper.TransactionOpenDate; ViewBag.Zone = erpDal.Zone(); // Need To Change After Riview List <GetLocationWiseEmployeeForEmployeeRegister> lstEmployeeRegister = new List <GetLocationWiseEmployeeForEmployeeRegister>(); lstEmployeeRegister = hrmsData.ReadGetLocationWiseEmployeeForEmployeeRegister(objLoginHelper.LogInForUnitCode); TempData["EmployeeRegister"] = lstEmployeeRegister; return(View()); }
public ActionResult CustomerRegisterForAuditor() { objLoginHelper = (LoginHelper)Session["LogInInformation"]; if (!securityDal.IsPageAccessible(Helper.ForSales, "CustomerRegisterForAuditor", objLoginHelper.UerRoleOrGroupID, Helper.Inactive, out message)) { Session["messageInformation"] = message; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } string CheckAuditSetup = hraDal.ReadAuditSeqNumberAfterCheckFinishedDate(objLoginHelper.LocationCode); if (string.IsNullOrEmpty(CheckAuditSetup)) { Session["messageInformation"] = "Please Configure Audit Setup First Before Any Transaction"; return(RedirectToAction("ErrorMessage", "../ErrorHnadle")); } //if (objLoginHelper.TransactionOpenDate == Helper.InvalidDate()) //{ // Session["messageInformation"] = "Day Is Not Open"; // return RedirectToAction("ErrorMessage", "../ErrorHnadle"); //} ViewBag.LocationTitle = objLoginHelper.LocationTitle; ViewBag.Location = objLoginHelper.Location; ViewBag.ZoneTitle = objLoginHelper.ZoneTitle; ViewBag.ZoneName = objLoginHelper.LogInForZoneName; ViewBag.RegionTitle = objLoginHelper.RegionTitle; ViewBag.RegionName = objLoginHelper.LogInForRegionName; ViewBag.UnitTitle = objLoginHelper.UnitTitle; ViewBag.UnitName = objLoginHelper.LogInForUnitName; ViewBag.OpenMonthYear = "Day Open Date: " + objLoginHelper.TransactionOpenDate.ToString("MMMM dd, yyyy"); //"Month: " + objLoginHelper.MonthOpenForSales.ToString("MMMM-yy"); ViewBag.ModuleName = objLoginHelper.ModluleTitle; ViewBag.TopMenu = objLoginHelper.TopMenu; ViewBag.OpenDay = objLoginHelper.TransactionOpenDate.Date.ToString("dd-MMM-yyyy"); ViewBag.OpenBackDay = objLoginHelper.TransactionBackDate.Date.ToString("dd-MMM-yyyy"); ViewBag.CalenderDate = objLoginHelper.MonthOpenForSales; ViewBag.Zone = erpDal.Zone(); List <UnitWiseCustomerRegisterReport> lstCustomerRegister = new List <UnitWiseCustomerRegisterReport>(); lstCustomerRegister = salesDal.ReadUnitWiseCustomerRegisterReport(objLoginHelper.LogInForUnitCode); ViewBag.TotalCollectionInCurrentMonth = lstCustomerRegister.Sum(s => s.CollectionInCurrentMonthWithoutDP).ToString("0"); ViewBag.TotalAdvance = ((decimal)lstCustomerRegister.Where(s => s.OverdueOrAdvanceBalance > 0).Sum(s => s.OverdueOrAdvanceBalance)).ToString("0"); ViewBag.TotalOverdue = ((decimal)lstCustomerRegister.Where(s => s.OverdueOrAdvanceBalance < 0).Sum(s => s.OverdueOrAdvanceBalance * -1)).ToString("0"); List <Aud_AdjustmentReasonCodes> newItemAdjustmentReason = new List <Aud_AdjustmentReasonCodes>(); newItemAdjustmentReason = inventoryDal.AuditAdjustMentReasons(Helper.ReasonPurposeForCollection[2], Helper.ReasonForUserOrAuditor, Helper.ForSales); ViewBag.AuditReasons = newItemAdjustmentReason; return(View(lstCustomerRegister)); }