Ejemplo n.º 1
0
        public EntityFrameworkUnitOfWork(MegaProjectContext context)//, IRepositoryProvider repositoryProvider)
        {
            Context = context;

            //repositoryProvider.Context = Context;
            //RepositoryProvider = repositoryProvider;
        }
Ejemplo n.º 2
0
        //, IRepositoryProvider repositoryProvider)
        public EntityFrameworkUnitOfWork(MegaProjectContext context)
        {
            Context = context;

            //repositoryProvider.Context = Context;
            //RepositoryProvider = repositoryProvider;
        }
Ejemplo n.º 3
0
        public Repository(IEFUnitOfWork unitOfWork)
        {
            if (unitOfWork == null)
            {
                throw new ArgumentNullException("unitOfWork");
            }

            _context = unitOfWork.Context;
        }
Ejemplo n.º 4
0
        public Repository(MegaProjectContext context)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            _context = context;
        }
Ejemplo n.º 5
0
 public Repository()
 {
     _context = new MegaProjectContext();
 }
Ejemplo n.º 6
0
        //protected IRepositoryProvider RepositoryProvider { get; set; }

        public EntityFrameworkUnitOfWork()
        {
            Context = new MegaProjectContext();
        }
Ejemplo n.º 7
0
 public void DbSetup()
 {
     Database.SetInitializer(new SeedingDatabaseInitializer());
     using (var ctx = new MegaProjectContext())
     {
         ctx.Database.Initialize(true);
     }
 }
Ejemplo n.º 8
0
 //protected IRepositoryProvider RepositoryProvider { get; set; }
 public EntityFrameworkUnitOfWork()
 {
     Context = new MegaProjectContext();
 }