public PartialViewResult InviteUser(int id, string userId) { SupportInvitation newInvitation = new SupportInvitation() { GoalId = id, FromUserId = User.Identity.GetUserId(), ToUserId = userId, SentDate = DateTime.Now }; supportInvitationService.CreateSupportInvitation(newInvitation); var user = userService.GetUser(userId); return(PartialView(user)); }
public void CreateSupportInvitation(SupportInvitation SupportInvitation) { SupportInvitationRepository.Add(SupportInvitation); SaveSupportInvitation(); }