/// <summary> /// Get the list of all request training list and bind the grid. /// </summary> /// <value>TrainingTypeID</value> public ActionResult ViewTechnicalTrainingRequestGrid(string trainingTypeID) { //create model and set all required field trainingID = Convert.ToInt32(trainingTypeID); TrainingModel objTrainingmodel = new TrainingModel(trainingTypeID); //check training type selected by user switch (trainingID) { case (CommonConstants.TechnicalTrainingID): //pass model and get the list of all technical training raise by manager viewTrainingListModel = _service.ViewTechnicalTraining(objTrainingmodel); break; case (CommonConstants.SoftSkillsTrainingID): //pass model and get the list of all Softskill training raise by manager viewTrainingListModel = _service.ViewSoftSkillsTraining(objTrainingmodel); break; case (CommonConstants.SeminarsID): //pass model and get the list of all seminar training raise by manager viewTrainingListModel = _service.ViewSeminarsTraining(objTrainingmodel); break; case (CommonConstants.KSSID): //pass model and get the list of all KSS training raise by manager viewTrainingListModel = _service.ViewKSSTraining(objTrainingmodel); break; } //set training type ID to be used for diaplaying training type column ViewData[CommonConstants.TrainingType] = string.IsNullOrWhiteSpace(trainingTypeID) ? CommonConstants.TechnicalTrainingID.ToString() : trainingTypeID; //set message on view page for required operation ViewData[CommonConstants.Result] = TempData[CommonConstants.Result]; return(View(CommonConstants.partialView_viewTrainingGrid, viewTrainingListModel)); }
/// <summary> /// Retrive Seminars Training summary. /// </summary> /// <returns>Collection</returns> public List <TrainingModel> ViewSeminarsTraining(TrainingModel RaiseTraining) { return(_repository.ViewSeminarsTraining(RaiseTraining)); }