public UnitOfWork(PPModel context)
 {
     this.context = context;
     context.Configuration.ProxyCreationEnabled = false;
     context.Configuration.LazyLoadingEnabled   = false;
     context.Database.CommandTimeout            = 300;
 }
        private static PPModel CreateModel()
        {
            var model = new PPModel();

            model.Configuration.ProxyCreationEnabled = false;
            model.Configuration.LazyLoadingEnabled   = false;
            model.Database.CommandTimeout            = 300;
            return(model);
        }
 public UnitOfWork()
 {
     context = CreateModel();
 }