public IActionResult AssignUserConfirm(UserAssignDto model)
        {
            TempData["Active"] = TempDataInfo.WorkOrder;
            UserAssignListDto assignUserModel = new UserAssignListDto
            {
                AppUser = _mapper.Map <AppUserListDto>(_userManager.Users.FirstOrDefault(I => I.Id == model.UserId)),
                Work    = _mapper.Map <WorkListDto>(_workService.FindByIdWithPriority(model.WorkId))
            };

            return(View(assignUserModel));
        }
Beispiel #2
0
        public IActionResult AssignUser(UserAssignDto model)
        {
            TempData["Active"] = TempdataInfo.TaskOperation;

            var userResult = _mapper.Map <AppUserListDto>(_userManager.Users.FirstOrDefault(x => x.Id == model.AppUserId));
            var taskResult = _mapper.Map <TaskListDto>(_taskService.GetByPriorityId(model.TaskId));

            UserAssignListDto userAssignModel = new UserAssignListDto
            {
                AppUser = userResult,
                Task    = taskResult
            };

            return(View(userAssignModel));
        }