public AnimatorsListPage()
        {
            InitializeComponent();
            BookYourDJEntities entities = new BookYourDJEntities();

            gridAnimators.ItemsSource = entities.Animators.ToList();
        }
        public override void Run(BookYourDJEntities context)
        {
            int regionId    = 0;
            var testRegions = faker
                              .RuleFor(u => u.Id, f => regionId++)
                              .RuleFor(u => u.Name, f => f.Address.Country())
                              .FinishWith((f, u) =>
            {
                logger.Info(CREATED_LOG_MSG, "Region", u.Id);
            });
            var regionsList = testRegions.Generate(10);

            context.Regions.AddRange(regionsList);
        }
        public override void Run(BookYourDJEntities context)
        {
            int animatorId = 0;

            var testAnimators = faker
                                .RuleFor(u => u.Id, f => animatorId++)
                                .RuleFor(u => u.FirstName, (f, u) => f.Name.FirstName())
                                .RuleFor(u => u.LastName, (f, u) => f.Name.LastName())
                                .RuleFor(u => u.Email, (f, u) => f.Internet.Email(u.FirstName, u.LastName))
                                .RuleFor(u => u.StageName, (f, u) => f.Hacker.Noun())
                                .RuleFor(u => u.Description, (f, u) => f.Lorem.Sentence())
                                .RuleFor(u => u.Birthday, (f, u) => f.Date.Past())
                                .RuleFor(u => u.Address, (f, u) => f.Address.FullAddress())
                                .RuleFor(u => u.Phone, (f, u) => f.Phone.PhoneNumber())

                                .FinishWith((f, u) =>
            {
                logger.Info(CREATED_LOG_MSG, "Animator", u.Id);
            });
            var a = testAnimators.Generate(50);

            context.Animators.AddRange(a);
        }
 public void Run(BookYourDJEntities context)
 {
     throw new NotImplementedException();
 }
Beispiel #5
0
 public abstract void Run(BookYourDJEntities context);