Esempio n. 1
0
        public UnitOfWork()
        {
            _yapartStoreContext            = new YapartStoreContext();
            BrandRepository                = new BrandRepository(_yapartStoreContext);
            CategoryRepository             = new CategoryRepository(_yapartStoreContext);
            GroupRepository                = new GroupRepository(_yapartStoreContext);
            SectionRepository              = new SectionRepository(_yapartStoreContext);
            ProductRepository              = new ProductRepository(_yapartStoreContext);
            PictureRepository              = new PictureRepository(_yapartStoreContext);
            OrderRepository                = new OrderRepository(_yapartStoreContext);
            OrderItemRepository            = new OrderItemRepository(_yapartStoreContext);
            MarkRepository                 = new MarkRepository(_yapartStoreContext);
            ModelRepository                = new ModelRepository(_yapartStoreContext);
            ModificationRepository         = new ModificationRepository(_yapartStoreContext);
            ProductModificationsRepository = new ProductModificationsRepository(_yapartStoreContext);

            UserRepository = new UserRepository(_yapartStoreContext,
                                                new UserManager <User, Guid>
                                                (
                                                    new CustomUserStore(_yapartStoreContext)
                                                ));
            RoleRepository = new RoleRepository(_yapartStoreContext,
                                                new RoleManager <CustomRole, Guid>
                                                (
                                                    new CustomRoleStore(_yapartStoreContext)
                                                ));
        }
Esempio n. 2
0
        public void TestMethod1()
        {
            var yapartContext = new YapartStoreContext();
            var models        = new ModelRepository(yapartContext);
            //Act
            var result = models.GetAll().ToList();

            //Assert
            var aa = 0;
        }
        public async Task GetAllModifications()
        {
            //Arrage
            var yapartContext = new YapartStoreContext();
            var modifications = new ModificationRepository(yapartContext);
            //Act
            var result = await modifications.GetAll().ToListAsync();

            //Assert
            var aa = 0;
        }
Esempio n. 4
0
        public async Task GetAllPicturesAsync()
        {
            //Arrage
            var yapartContext = new YapartStoreContext();
            var pictures      = new PictureRepository(yapartContext);
            //Act
            var result = await pictures.GetAll().ToListAsync();

            //Assert
            var aa = 0;
        }
        public void ChangeNameForLink()
        {
            //Arrage
            var yapartContext = new YapartStoreContext();
            var modifications = new ModificationRepository(yapartContext);

            //Act
            modifications.ChangeNameForLink();

            //Assert
            var aa = 0;
        }
Esempio n. 6
0
 public PictureRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 7
0
 public OrderRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 8
0
 public UserRepository(YapartStoreContext yapartStoreContext, UserManager <User, Guid> userManager)
 {
     _yapartStoreContext = yapartStoreContext;
     _userManager        = userManager;
 }
Esempio n. 9
0
 public CustomRoleStore(YapartStoreContext yapartStoreContext)
     : base(yapartStoreContext)
 {
 }
Esempio n. 10
0
 public MarkRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 11
0
 public RoleRepository(YapartStoreContext yapartStoreContext, RoleManager <CustomRole, Guid> roleManager)
 {
     _yapartStoreContext = yapartStoreContext;
     _roleManager        = roleManager;
 }
Esempio n. 12
0
 public BrandRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
 public ModificationRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 14
0
 public SectionRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 15
0
 public ProductModificationsRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 16
0
 public CustomUserStore(YapartStoreContext yapartStoreContext) : base(yapartStoreContext)
 {
 }
Esempio n. 17
0
 public GroupRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 18
0
 public CategoryRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }
Esempio n. 19
0
 public ProductRepository(YapartStoreContext yapartStoreContext)
 {
     _yapartStoreContext = yapartStoreContext;
 }