예제 #1
0
        public ActionResult Employee(int id)
        {
            if (Session[SessionConstants.Company] == null)
            {
                return(View(LoginPage));
            }

            ViewBag.Employee = model.GetEmployee(id, GetSessionCompany().CompanyId);

            Assesment assesment = model.GetEmployeeAssesment(id, GetSessionCompany().CompanyId);

            if (assesment != null)
            {
                ViewBag.Assesment = assesment.GetInfo();
                if (assesment.GetInfo().Status == AssesmentStatus.Done)
                {
                    ViewBag.AssesmentReport = assesment.GetReport();
                }
            }

            return(View(GetSessionCompany()));
        }