public void Update(IUserType userType) { Type = userType.Type; if (userType.Users != null) { foreach (var item in userType.Users) { UserEntities.Add(new UserEntity(item)); } } }
public void Update(ISource source) { Name = source.Name; SecretKey = source.SecretKey; if (source.Users != null) { foreach (var item in source.Users) { UserEntities.Add(new UserEntity(item)); } } }
public UserTypeEntity(IUserType userType) { Id = Guid.NewGuid(); Type = userType.Type; if (userType.Users != null) { foreach (var item in userType.Users) { UserEntities.Add(new UserEntity(item)); } } }
public SourceEntity(ISource source) { Id = Guid.NewGuid(); Name = source.Name; SecretKey = source.SecretKey; if (source.Users != null) { foreach (var item in source.Users) { UserEntities.Add(new UserEntity(item)); } } }
public void Update(ISegment segment) { Name = segment.Name; Cron = segment.Cron; IsActive = segment.IsActive; SqlExpression = segment.SqlExpression; if (segment.Users != null) { foreach (var item in segment.Users) { UserEntities.Add(new UserEntity(item)); } } if (segment.Emails != null) { foreach (var item in segment.Emails) { EmailEntities.Add(new EmailEntity(item)); } } }
public SegmentEntity(ISegment segment) { Id = Guid.NewGuid(); Name = segment.Name; Cron = segment.Cron; IsActive = segment.IsActive; SqlExpression = segment.SqlExpression; if (segment.Users != null) { foreach (var item in segment.Users) { UserEntities.Add(new UserEntity(item)); } } if (segment.Emails != null) { foreach (var item in segment.Emails) { EmailEntities.Add(new EmailEntity(item)); } } }