Esempio n. 1
0
        public ActionResult Create3(VMLeaveCFSelection es, int?[] SelectedEmpIds)
        {
            VMLeaveCF vmLeaveCF = new VMLeaveCF();

            vmLeaveCF = LeaveCFService.GetCreate3(es, SelectedEmpIds, vmLeaveCF);
            return(View(vmLeaveCF));
        }
Esempio n. 2
0
        /// <summary>
        /// Shows the list of all Leave Carry Forward of selected employees.
        /// </summary>
        /// <param name="es"></param>
        /// <param name="SelectedEmployeeIds">Parameter of Selected Employee ids</param>
        /// <param name="vmLeaveCF"></param>
        /// <returns></returns>
        /// <remarks></remarks>
        public VMLeaveCF GetCreate3(VMLeaveCFSelection es, int?[] SelectedEmployeeIds, VMLeaveCF vmLeaveCF)
        {
            List <VMLeaveCFChild>      vmLeaveCFChildList = new List <VMLeaveCFChild>();
            List <VHR_EmployeeProfile> employees          = DDService.GetEmployeeInfo();                                       // Get All Employees from database
            FinancialYear financialYear = DDService.GetFinancialYear().First(aa => aa.PFinancialYearID == es.FinancialYearID); // Get selected financial year

            foreach (int empid in SelectedEmployeeIds)
            {
                VMLeaveCFChild      vmLeaveCFChild = new VMLeaveCFChild();
                VHR_EmployeeProfile employee       = employees.First(aa => aa.PEmployeeID == empid);// Get Specific Employee

                vmLeaveCFChild.EmpID             = employee.PEmployeeID;
                vmLeaveCFChild.EmpNo             = employee.OEmpID;
                vmLeaveCFChild.EmployeeName      = employee.EmployeeName;
                vmLeaveCFChild.FinancialYearID   = financialYear.PFinancialYearID;
                vmLeaveCFChild.FinancialYearName = financialYear.FYName;
                vmLeaveCFChild.TotalLeave        = 20;
                vmLeaveCFChild.LeaveTypeName     = "AL";
                vmLeaveCFChild.CarryForward      = 15;
                vmLeaveCFChild.CollapseLeave     = 5;
                vmLeaveCFChildList.Add(vmLeaveCFChild);
            }
            vmLeaveCF.FinancialYearID   = financialYear.PFinancialYearID;
            vmLeaveCF.FinancialYearName = financialYear.FYName;
            vmLeaveCF.LeaveCFChild      = vmLeaveCFChildList;
            return(vmLeaveCF);
        }
Esempio n. 3
0
        public ActionResult Create1()
        {
            VMLeaveCFSelection vmJobCardCreate = new VMLeaveCFSelection();

            vmJobCardCreate         = LeaveCFService.GetCreate1();
            ViewBag.FinancialYearID = new SelectList(DDService.GetFinancialYear().ToList().OrderBy(aa => aa.FYName).ToList(), "PFinancialYearID", "FYName");
            return(View(vmJobCardCreate));
        }
Esempio n. 4
0
        public ActionResult Create1(VMLeaveCFSelection es, int?[] SelectedCompanyIds, int?[] SelectedOUCommonIds, int?[] SelectedOUIds, int?[] SelectedEmploymentTypeIds,
                                    int?[] SelectedLocationIds, int?[] SelectedGradeIds, int?[] SelectedJobTitleIds, int?[] SelectedDesignationIds,
                                    int?[] SelectedCrewIds, int?[] SelectedShiftIds)
        {
            VMLoggedUser LoggedInUser = Session["LoggedInUser"] as VMLoggedUser;

            es = LeaveCFService.GetCreate2(es, SelectedCompanyIds, SelectedOUCommonIds, SelectedOUIds, SelectedEmploymentTypeIds,
                                           SelectedLocationIds, SelectedGradeIds, SelectedJobTitleIds, SelectedDesignationIds,
                                           SelectedCrewIds, SelectedShiftIds, LoggedInUser);
            return(View("Create2", es));
        }
Esempio n. 5
0
        }      /// <summary>

        ///  This method gets the information of selected filter
        /// </summary>
        /// <param name="es"> Gets the information of Selected employee for Leave Carry Forward. </param>
        /// <param name="SelectedOUCommonIds">Parameter of Common OU</param>
        /// <param name="SelectedOUIds">Parameter of OU </param>
        /// <param name="SelectedEmploymentTypeIds">Selected Employee types</param>
        /// <param name="SelectedLocationIds">Selected Locations</param>
        /// <param name="SelectedGradeIds">Selected Grades </param>
        /// <param name="SelectedJobTitleIds">Selected Job titles</param>
        /// <param name="SelectedDesignationIds">Slected Designations</param>
        /// <param name="SelectedCrewIds">Selected Crews./param>
        /// <param name="SelectedShiftIds">Selected Shifts</param>
        /// <param name="LoggedInUser">Logged in User </param>
        /// <returns></returns>
        /// <remarks></remarks>
        public VMLeaveCFSelection GetCreate2(VMLeaveCFSelection es, int?[] SelectedCompanyIds, int?[] SelectedOUCommonIds, int?[] SelectedOUIds, int?[] SelectedEmploymentTypeIds,
                                             int?[] SelectedLocationIds, int?[] SelectedGradeIds, int?[] SelectedJobTitleIds, int?[] SelectedDesignationIds,
                                             int?[] SelectedCrewIds, int?[] SelectedShiftIds, VMLoggedUser LoggedInUser)
        {
            VMEmpSelection vmEmpSelection = EmpSelectionService.GetStepTwo(SelectedCompanyIds,
                                                                           SelectedOUCommonIds, SelectedOUIds, SelectedEmploymentTypeIds,
                                                                           SelectedLocationIds, SelectedGradeIds, SelectedJobTitleIds, SelectedDesignationIds,
                                                                           SelectedCrewIds, SelectedShiftIds, es.EmpNo, LoggedInUser);

            es.Criteria          = vmEmpSelection.Criteria;
            es.CriteriaName      = vmEmpSelection.CriteriaName;
            es.EmpNo             = vmEmpSelection.EmpNo;
            es.Employee          = vmEmpSelection.Employee;
            es.FinancialYearName = DDService.GetFinancialYear().Where(aa => aa.PFinancialYearID == es.FinancialYearID).First().FYName;
            return(es);
        }
Esempio n. 6
0
        /// <summary>
        /// Gets the filters fo the creation of leave carry forward
        /// </summary>
        /// <returns></returns>
        public VMLeaveCFSelection GetCreate1()
        {
            VMLeaveCFSelection obj = new VMLeaveCFSelection();

            return(obj);
        }      /// <summary>