Ejemplo n.º 1
0
        public ActionResult Index()
        {
            var emp = Utility.GetEmployeeSession(Session);

            switch ((RoleEnum)emp.RoleId)
            {
            case RoleEnum.ProductOwner:
                ViewBag.Data = Utility.ConvertToProductSummary(productService.GetAllProductBackLogsByOwner(emp.Id));
                break;

            case RoleEnum.ScrumMaster:
                ViewBag.Data = Utility.ConvertToSprintSummary(sprintService.GetAll().Where(i => i.ReleaseBacklog.ScrumMasterId == emp.Id));
                break;

            case RoleEnum.HR:
                break;

            case RoleEnum.Developer:
                ViewBag.Data = usService.GetAllByDeveloperId(emp.Id);
                break;

            case RoleEnum.Tester:
                ViewBag.Data = usService.GetAllByTesterId(emp.Id);
                break;
            }
            return(View());
        }
Ejemplo n.º 2
0
 public ActionResult GetUserStoriesByUId(int UserId)
 {
     if (Utility.UserInRole(RoleEnum.Developer, Session))
     {
         return(View("Index", service.GetAllByDeveloperId(UserId)));
     }
     else
     {
         return(View("Index", service.GetAllByTesterId(UserId)));
     }
 }