예제 #1
0
        public User GetByUsernameAndPassword(string username, string password)
        {
            VinylStoreDbContext context = new VinylStoreDbContext();

            return(context.Users.Where(i => i.Username == username &&
                                       i.Password == password).FirstOrDefault());
        }
예제 #2
0
 public BaseRepository()
 {
     context = new VinylStoreDbContext();
     items   = context.Set <T>();
 }