public System.Collections.Generic.IEnumerable<NorthwindWebNHibernate.Business.Territories> Search(string territoryId, string territoryDescription, NorthwindWebNHibernate.Business.Region fkTerritoriesRegion) { return _context.NorthwindDbo.CreateCriteria<NorthwindWebNHibernate.Business.Territories>() .Add(NHibernate.Criterion.Restrictions.Eq("territoryId", territoryId)) .Add(NHibernate.Criterion.Restrictions.Eq("territoryDescription", territoryDescription)) .Add(NHibernate.Criterion.Restrictions.Eq("fkTerritoriesRegion", fkTerritoriesRegion)) .List<NorthwindWebNHibernate.Business.Territories>(); }
public void Update(NorthwindWebNHibernate.Business.Sysdiagrams v) { using(NHibernate.ITransaction tx = _context.NorthwindDbo.BeginTransaction()) { try { _context.NorthwindDbo.Update(v); tx.Commit(); } catch { tx.Rollback(); throw; } } }
public void Delete(NorthwindWebNHibernate.Business.Categories v) { using (NHibernate.ITransaction tx = _context.NorthwindDbo.BeginTransaction()) { try { _context.NorthwindDbo.Delete(v); tx.Commit(); } catch { tx.Rollback(); throw; } } }
public void Create(NorthwindWebNHibernate.Business.Customers v) { using(NHibernate.ITransaction tx = _context.NorthwindDbo.BeginTransaction()) { try { _context.NorthwindDbo.Save(v); tx.Commit(); } catch { tx.Rollback(); throw; } } }
public System.Collections.Generic.IEnumerable<NorthwindWebNHibernate.Business.Products> Search(int productId, string productName, string quantityPerUnit, decimal unitPrice, short unitsInStock, short unitsOnOrder, short reorderLevel, bool discontinued, NorthwindWebNHibernate.Business.Categories fkProductsCategories, NorthwindWebNHibernate.Business.Suppliers fkProductsSuppliers) { return _context.NorthwindDbo.CreateCriteria<NorthwindWebNHibernate.Business.Products>() .Add(NHibernate.Criterion.Restrictions.Eq("productId", productId)) .Add(NHibernate.Criterion.Restrictions.Eq("productName", productName)) .Add(NHibernate.Criterion.Restrictions.Eq("quantityPerUnit", quantityPerUnit)) .Add(NHibernate.Criterion.Restrictions.Eq("unitPrice", unitPrice)) .Add(NHibernate.Criterion.Restrictions.Eq("unitsInStock", unitsInStock)) .Add(NHibernate.Criterion.Restrictions.Eq("unitsOnOrder", unitsOnOrder)) .Add(NHibernate.Criterion.Restrictions.Eq("reorderLevel", reorderLevel)) .Add(NHibernate.Criterion.Restrictions.Eq("discontinued", discontinued)) .Add(NHibernate.Criterion.Restrictions.Eq("fkProductsCategories", fkProductsCategories)) .Add(NHibernate.Criterion.Restrictions.Eq("fkProductsSuppliers", fkProductsSuppliers)) .List<NorthwindWebNHibernate.Business.Products>(); }
public System.Collections.Generic.IEnumerable<NorthwindWebNHibernate.Business.Orders> Search(int orderId, System.DateTime? orderDate, System.DateTime? requiredDate, System.DateTime? shippedDate, decimal freight, string shipName, string shipAddress, string shipCity, string shipRegion, string shipPostalCode, string shipCountry, NorthwindWebNHibernate.Business.Customers fkOrdersCustomers, NorthwindWebNHibernate.Business.Employees fkOrdersEmployees, NorthwindWebNHibernate.Business.Shippers fkOrdersShippers) { return _context.NorthwindDbo.CreateCriteria<NorthwindWebNHibernate.Business.Orders>() .Add(NHibernate.Criterion.Restrictions.Eq("orderId", orderId)) .Add(NHibernate.Criterion.Restrictions.Eq("orderDate", orderDate)) .Add(NHibernate.Criterion.Restrictions.Eq("requiredDate", requiredDate)) .Add(NHibernate.Criterion.Restrictions.Eq("shippedDate", shippedDate)) .Add(NHibernate.Criterion.Restrictions.Eq("freight", freight)) .Add(NHibernate.Criterion.Restrictions.Eq("shipName", shipName)) .Add(NHibernate.Criterion.Restrictions.Eq("shipAddress", shipAddress)) .Add(NHibernate.Criterion.Restrictions.Eq("shipCity", shipCity)) .Add(NHibernate.Criterion.Restrictions.Eq("shipRegion", shipRegion)) .Add(NHibernate.Criterion.Restrictions.Eq("shipPostalCode", shipPostalCode)) .Add(NHibernate.Criterion.Restrictions.Eq("shipCountry", shipCountry)) .Add(NHibernate.Criterion.Restrictions.Eq("fkOrdersCustomers", fkOrdersCustomers)) .Add(NHibernate.Criterion.Restrictions.Eq("fkOrdersEmployees", fkOrdersEmployees)) .Add(NHibernate.Criterion.Restrictions.Eq("fkOrdersShippers", fkOrdersShippers)) .List<NorthwindWebNHibernate.Business.Orders>(); }
public SysdiagramsRepository(NorthwindWebNHibernate.Context context) { _context = context; }
public CategoriesRepository(NorthwindWebNHibernate.Context context) { _context = context; }
public CustomersRepository(NorthwindWebNHibernate.Context context) { _context = context; }
public ProductsRepository(NorthwindWebNHibernate.Context context) { _context = context; }
public ShippersRepository(NorthwindWebNHibernate.Context context) { _context = context; }