Esempio n. 1
0
        public IEnumerable <Product> SanPhamCungTheLoai(string searchString, long catelogID)
        {
            ShopXeDapDbContext   db        = new ShopXeDapDbContext();
            IQueryable <Product> dsProduct = db.Products;

            if (!string.IsNullOrEmpty(searchString))
            {
                dsProduct = dsProduct.Where(x => x.Name.Contains(searchString) || x.Code.Contains(searchString));
            }
            return(dsProduct.Where(x => x.CategoryID == catelogID).ToList());
        }
 public FeedbackDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 3
0
 public ProductCategoryDao()
 {
     db = new ShopXeDapDbContext();
 }
 public ProductDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 5
0
 public OrderDao()
 {
     db = new ShopXeDapDbContext();
 }
 public UserGroupDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 7
0
 public SlideDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 8
0
 public FooterDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 9
0
 public MenuDao()
 {
     db = new ShopXeDapDbContext();
 }
Esempio n. 10
0
 public ContactDao()
 {
     db = new ShopXeDapDbContext();
 }