public ActionResult Index()
 {
     using (var context = new InternetShopContext())
     {
         context.Users.Add(new User()
         {
             Password = "******", ConfirmPassword = "******", Surname = "Vasiy", Name = "Petya"
         });
         var a = context.Users;
     }
     return(View());
 }
Ejemplo n.º 2
0
 public OrderItemRepository(InternetShopContext context)
 {
     db = context;
 }
Ejemplo n.º 3
0
 public BasketRepository(InternetShopContext db)
 {
     this.db    = db;
     this.dbSet = db.Set <Basket>();
 }
 public ProductRepository(InternetShopContext db)
 {
     this.db    = db;
     this.dbSet = db.Set <Product>();
 }
Ejemplo n.º 5
0
 public OrderRepository(InternetShopContext db)
 {
     this.db    = db;
     this.dbSet = db.Set <Order>();
 }
Ejemplo n.º 6
0
 public UnitOfWork(IInternetShopContext context)
 {
     this.context = context as InternetShopContext;
 }
Ejemplo n.º 7
0
 public CustomerRepository(InternetShopContext context)
 {
     db = context;
 }
 public EFUnitOfWork(InternetShopContext internetShopContext)
 {
     _db = internetShopContext;
 }