/// <summary> /// Applications the start. /// </summary> protected void Application_Start() { AreaRegistration.RegisterAllAreas(); GlobalConfiguration.Configure(WebApiConfig.Register); FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); BundleConfig.RegisterBundles(BundleTable.Bundles); DbInterceptors.Init(); }
public static UnityContainer RegisterService() { DbInterceptors.Init(); // Web API configuration and services container = new UnityContainer(); #region quản lý danh muc dùng chung container.RegisterType <ISystemUserService, SystemUserService>(new InjectionConstructor()); container.RegisterType <ISystemModuleService, SystemModuleService>(new InjectionConstructor()); #endregion return(container); }
public void Init() { DbInterceptors.Init(); }
public IndividualPersonRepository(OrgManEntities context) : base(context) { DbInterceptors.Init(); }
public ApplicationDbContext() : base("DefaultConnection", false) { DbInterceptors.Init(); }
/// <summary> /// Enables the Entity Framework FTS interceptors. /// </summary> /// <param name="dbContext">The database context.</param> /// <remarks> /// Using library: /// https://github.com/fissoft/Fissoft.EntityFramework.Fts /// </remarks> /// <example> /// var text = FullTextSearchModelUtil.ContainsAll("code ef"); /// db.Tables.Where(c=>"*".Contains(text)); /// </example> /// <example> /// var text = FullTextSearchModelUtil.Contains("code"); /// db.Tables.Where(c=>c.Fullname.Contains(text)); /// </example> public static void EnableEfFts(this ApplicationDbContext dbContext) { DbInterceptors.Init(); }