public IActionResult Activity(int id) { if (HttpContext.Session.GetInt32("id") != null) { ShowActivity data = new ShowActivity { Activity = _context.Activities.Where(a => a.ID == id).Include(a => a.User).Include(a => a.Participants).ThenInclude(p => p.User).SingleOrDefault(), User = _context.Users.Where(u => u.ID == HttpContext.Session.GetInt32("id")).SingleOrDefault(), }; return(View(data)); } return(RedirectToAction("Index", "User")); }
public bool Equals(GeneralUser input) { if (input == null) { return(false); } return (( MembershipId == input.MembershipId || (MembershipId.Equals(input.MembershipId)) ) && ( UniqueName == input.UniqueName || (UniqueName != null && UniqueName.Equals(input.UniqueName)) ) && ( NormalizedName == input.NormalizedName || (NormalizedName != null && NormalizedName.Equals(input.NormalizedName)) ) && ( DisplayName == input.DisplayName || (DisplayName != null && DisplayName.Equals(input.DisplayName)) ) && ( ProfilePicture == input.ProfilePicture || (ProfilePicture.Equals(input.ProfilePicture)) ) && ( ProfileTheme == input.ProfileTheme || (ProfileTheme.Equals(input.ProfileTheme)) ) && ( UserTitle == input.UserTitle || (UserTitle.Equals(input.UserTitle)) ) && ( SuccessMessageFlags == input.SuccessMessageFlags || (SuccessMessageFlags.Equals(input.SuccessMessageFlags)) ) && ( IsDeleted == input.IsDeleted || (IsDeleted != null && IsDeleted.Equals(input.IsDeleted)) ) && ( About == input.About || (About != null && About.Equals(input.About)) ) && ( FirstAccess == input.FirstAccess || (FirstAccess != null && FirstAccess.Equals(input.FirstAccess)) ) && ( LastUpdate == input.LastUpdate || (LastUpdate != null && LastUpdate.Equals(input.LastUpdate)) ) && ( LegacyPortalUid == input.LegacyPortalUid || (LegacyPortalUid.Equals(input.LegacyPortalUid)) ) && ( Context == input.Context || (Context != null && Context.Equals(input.Context)) ) && ( PsnDisplayName == input.PsnDisplayName || (PsnDisplayName != null && PsnDisplayName.Equals(input.PsnDisplayName)) ) && ( XboxDisplayName == input.XboxDisplayName || (XboxDisplayName != null && XboxDisplayName.Equals(input.XboxDisplayName)) ) && ( FbDisplayName == input.FbDisplayName || (FbDisplayName != null && FbDisplayName.Equals(input.FbDisplayName)) ) && ( ShowActivity == input.ShowActivity || (ShowActivity != null && ShowActivity.Equals(input.ShowActivity)) ) && ( Locale == input.Locale || (Locale != null && Locale.Equals(input.Locale)) ) && ( LocaleInheritDefault == input.LocaleInheritDefault || (LocaleInheritDefault != null && LocaleInheritDefault.Equals(input.LocaleInheritDefault)) ) && ( LastBanReportId == input.LastBanReportId || (LastBanReportId.Equals(input.LastBanReportId)) ) && ( ShowGroupMessaging == input.ShowGroupMessaging || (ShowGroupMessaging != null && ShowGroupMessaging.Equals(input.ShowGroupMessaging)) ) && ( ProfilePicturePath == input.ProfilePicturePath || (ProfilePicturePath != null && ProfilePicturePath.Equals(input.ProfilePicturePath)) ) && ( ProfilePictureWidePath == input.ProfilePictureWidePath || (ProfilePictureWidePath != null && ProfilePictureWidePath.Equals(input.ProfilePictureWidePath)) ) && ( ProfileThemeName == input.ProfileThemeName || (ProfileThemeName != null && ProfileThemeName.Equals(input.ProfileThemeName)) ) && ( UserTitleDisplay == input.UserTitleDisplay || (UserTitleDisplay != null && UserTitleDisplay.Equals(input.UserTitleDisplay)) ) && ( StatusText == input.StatusText || (StatusText != null && StatusText.Equals(input.StatusText)) ) && ( StatusDate == input.StatusDate || (StatusDate != null && StatusDate.Equals(input.StatusDate)) ) && ( ProfileBanExpire == input.ProfileBanExpire || (ProfileBanExpire != null && ProfileBanExpire.Equals(input.ProfileBanExpire)) ) && ( BlizzardDisplayName == input.BlizzardDisplayName || (BlizzardDisplayName != null && BlizzardDisplayName.Equals(input.BlizzardDisplayName)) ) && ( SteamDisplayName == input.SteamDisplayName || (SteamDisplayName != null && SteamDisplayName.Equals(input.SteamDisplayName)) ) && ( StadiaDisplayName == input.StadiaDisplayName || (StadiaDisplayName != null && StadiaDisplayName.Equals(input.StadiaDisplayName)) ) && ( TwitchDisplayName == input.TwitchDisplayName || (TwitchDisplayName != null && TwitchDisplayName.Equals(input.TwitchDisplayName)) ) && ( CachedBungieGlobalDisplayName == input.CachedBungieGlobalDisplayName || (CachedBungieGlobalDisplayName != null && CachedBungieGlobalDisplayName.Equals(input.CachedBungieGlobalDisplayName)) ) && ( CachedBungieGlobalDisplayNameCode == input.CachedBungieGlobalDisplayNameCode || (CachedBungieGlobalDisplayNameCode.Equals(input.CachedBungieGlobalDisplayNameCode)) )); }