Example #1
0
        public ActionResult PerformanceCoachingandReview(int taskid, int?id)
        {
            PMSPageInfo PI = new PMSPageInfo();

            if (id.HasValue)
            {
                var temp = PMSModel.GetApprisalByID(id.Value);
                ViewData["Stage"]  = temp.Stage;
                ViewData["Status"] = temp.Status;
                PI.ApprisalId      = id.Value;
                PI.TaskId          = taskid;
                PMSHelper.GetSectionInfo(PI, id.Value);
            }

            int sectionId = PMSHelper.GetCurrentSectionID(PI.SCList, RouteData.Values["Action"].ToString());

            PI.CurSectionId = sectionId;
            PMSHelper.GetBlockInfo(PI, sectionId);

            PMSHelper.GetPerformanceCoaching(PI, id.Value);
            List <PMSCommentsInfo> comments    = new List <PMSCommentsInfo>();
            PMSCommentsInfo        curcomments = new PMSCommentsInfo();

            PI.pcInfo.Comments   = PMSModel.GetCommentsInfoByPerformanceID(PI.pcInfo.ID, out curcomments);
            PI.pcInfo.CurComment = curcomments;
            //foreach()
            ViewData.Model = PI;
            return(View());
        }
Example #2
0
        public ActionResult CoreValues(int?id)
        {
            PMSPageInfo PI = new PMSPageInfo();

            if (id.HasValue)
            {
                var temp = PMSModel.GetApprisalByID(id.Value);
                ViewData["Stage"]  = temp.Stage;
                ViewData["Status"] = temp.Status;
                PI.StageID         = PMSModel.GetCurrentStageID(id.Value);
                PMSHelper.GetSectionInfo(PI, id.Value);
                PI.ApprisalId = id.Value;
                int sectionId = PMSHelper.GetCurrentSectionID(PI.SCList, RouteData.Values["Action"].ToString());
                PMSHelper.GetBlockInfo(PI, sectionId);
                List <PMSCommentsInfo> comments = new List <PMSCommentsInfo>();
                PMSHelper.GetCoreValuesList(PI, id.Value);
                comments = PMSHelper.GetAllCoreValuesComments(PI.CoreValuesList);
                if (comments.Count > 0)
                {
                    foreach (PMSCoreValuesInfo kpiinfo in PI.CoreValuesList)
                    {
                        PMSHelper.GetEachCoreValuesComments(kpiinfo, comments);
                    }
                }
            }
            ViewData.Model = PI;
            return(View());
        }
Example #3
0
        //
        // GET: /Stage3/

        public ActionResult KeyPerformanceIndicators(int taskid, int?id)
        {
            PMSPageInfo PI = new PMSPageInfo();

            if (id.HasValue)
            {
                var temp = PMSModel.GetApprisalByID(id.Value);
                ViewData["Stage"]  = temp.Stage;
                ViewData["Status"] = temp.Status;
                PMSHelper.GetSectionInfo(PI, id.Value);
                PI.ApprisalId = id.Value;
                PI.TaskId     = taskid;
                int sectionId = PMSHelper.GetCurrentSectionID(PI.SCList, RouteData.Values["Action"].ToString());
                PI.CurSectionId = sectionId;
                PMSHelper.GetBlockInfo(PI, sectionId);
                List <PMSCommentsInfo> comments = new List <PMSCommentsInfo>();
                PMSHelper.GetKPIList(PI, id.Value);
                comments = PMSHelper.GetAllKPIComments(PI.KPIList);
                if (comments.Count > 0)
                {
                    foreach (PMSKPIInfo kpiinfo in PI.KPIList)
                    {
                        PMSHelper.GetEachKPIComments(kpiinfo, comments);
                    }
                }
            }
            ViewData.Model = PI;
            return(View());
        }
Example #4
0
        public ActionResult PerformanceCoachingandReview(int taskid, int id, FormCollection form)
        {
            string message = string.Empty;
            int    status  = PMSModel.GetApprisalByID(id).StatusID;

            if (PMSModel.OnlyUpdateApprStatus(id, (int)ApprStatus.Draft, PMSHelper.GetApprovalLevel(id, UserInfo.userinfo.ID), form["ApORRe"].ToString(), out message))
            {
                TempData["AlertMessage"] = "PerformanceCoaching data saved successfully";
                return(Redirect("/Stage1Approval/CareerDevelopment/" + taskid + "/" + id));
            }
            else
            {
                TempData["AlertMessage"] = "Ops! PerformanceCoaching data saving failed, please try again or contact IT member";
                return(View());
            }
        }
Example #5
0
        public ActionResult CareerDevelopment(int taskid, int id, FormCollection form)
        {
            string message = string.Empty;
            Dictionary <string, string> dictform = new Dictionary <string, string>();

            dictform.Add("ModuleID", ModuleID.ToString());
            dictform.Add("TaskID", taskid.ToString());
            dictform.Add("UserID", UserInfo.userinfo.ID.ToString());
            dictform.Add("ApprID", id.ToString());
            int ApprovalLevel = PMSHelper.GetApprovalLevel(id, UserInfo.userinfo.ID);
            int status        = PMSModel.GetApprisalByID(id).StatusID;

            if (PMSModel.FinishTaskAndUpdateApprStatus(dictform, status, ApprovalLevel, "", out message))
            {
                TempData["AlertMessage"] = "CarrerDevelopment data saved successfully";
                return(Redirect("/"));
            }
            else
            {
                TempData["AlertMessage"] = "Ops! CarrerDevelopment data saving failed, please try again or contact IT member";
                return(View());
            }
        }