public SocialAccount MarkAsEnable(int id, bool?ifEnable = true) { var account = this.Find(id); if (account == null) { throw SocialExceptions.SocialUserIdNotExists(id); } account.IfEnable = ifEnable.Value; this.Update(account); return(account); }
public IList <ConversationDto> FindConversations(int socialUserId) { SocialUser user = _domainService.Find(socialUserId); if (user == null) { throw SocialExceptions.SocialUserIdNotExists(socialUserId); } ConversationSearchDto searchDto = new ConversationSearchDto(); if (user != null) { searchDto.UserId = user.Id; return(_conversationService.Find(searchDto)); } return(null); }