public RequisitionService() { _context = new SCHMDbContext(); _storeUnitOfWork = new StoreUnitOfWork(_context); _ProductUnitOfWork = new ProductUnitOfWork(_context); _RequisitionUnitOfWork = new RequisitionUnitOfWork(_context); }
public ActionResult About() { SmartShopContext db = new SmartShopContext(); ProductUnitOfWork uow = new ProductUnitOfWork(db); Product p = new Product(); p.ProductName = "Shovon"; p.ProductPrice = 100; uow.ProductRepository.Add(p); uow.Save(); uow.ProductRepository.GetAll(); ViewBag.Message = "Your application description page."; return(View()); }
public ProductService() { _context = new SCHMDbContext(); _ProductUnitOfWork = new ProductUnitOfWork(_context); }
public StoreService() { _context = new SCHMDbContext(); _storeUnitOfWork = new StoreUnitOfWork(_context); _ProductUnitOfWork = new ProductUnitOfWork(_context); }