예제 #1
0
        public ActionResult AddSupportToGoal()
        {
            Guid goalIdToken = (Guid)TempData["goToken"];
            var  goalId      = securityTokenService.GetActualId(goalIdToken);

            supportService.CreateSupport(new Support()
            {
                UserId = User.Identity.GetUserId(), GoalId = goalId, SupportedDate = DateTime.Now
            });
            securityTokenService.DeleteSecurityToken(goalIdToken);
            MuhendislerBuradaSessionFacade.Remove(MuhendislerBuradaSessionFacade.JoinGroupOrGoal);
            return(RedirectToAction("Index", "Home"));
        }
예제 #2
0
        public ActionResult AddGroupUser()
        {
            Guid      groupIdToken = (Guid)TempData["grToken"];
            var       groupId      = securityTokenService.GetActualId(groupIdToken);
            GroupUser newGroupUser = new GroupUser()
            {
                UserId  = User.Identity.GetUserId(),
                GroupId = groupId,
                Admin   = false
            };

            groupUserService.CreateGroupUser(newGroupUser, groupInvitationService);
            securityTokenService.DeleteSecurityToken(groupIdToken);
            MuhendislerBuradaSessionFacade.Remove(MuhendislerBuradaSessionFacade.JoinGroupOrGoal);
            return(RedirectToAction("Index", "Home"));
        }
예제 #3
0
 //
 // POST: /Account/LogOff
 //[HttpPost]
 //[ValidateAntiForgeryToken]
 public ActionResult LogOff()
 {
     AuthenticationManager.SignOut();
     MuhendislerBuradaSessionFacade.Clear();
     return(RedirectToAction("Index", "Home"));
 }