Пример #1
0
 protected void Application_Start()
 {
     AreaRegistration.RegisterAllAreas();
     GlobalConfiguration.Configure(WebApiConfig.Register);
     FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
     AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
 }
Пример #2
0
 void Application_Start(object sender, EventArgs e)
 {
     // Code that runs on application startup
     AreaRegistration.RegisterAllAreas();
     GlobalConfiguration.Configure(WebApiConfig.Register);
     AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
 }
Пример #3
0
 void Application_Start(object sender, EventArgs e)
 {
     AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
     AreaRegistration.RegisterAllAreas();
     GlobalConfiguration.Configure(WebApiConfig.Register);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
     BundleConfig.RegisterBundle(BundleTable.Bundles);
 }
Пример #4
0
        public void Configuration(IAppBuilder app)
        {
            var configuration = new HttpConfiguration();

            WebApiConfig.Register(configuration);
            AutofacWebApiConfig.Initialize(configuration);

            app.UseWebApi(configuration);
        }
Пример #5
0
        public void Configuration(IAppBuilder app)
        {
            AreaRegistration.RegisterAllAreas();
            GlobalConfiguration.Configure(WebApiConfig.Register);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);


            Container = AutofacWebApiConfig.Initialize();

            AutoMapperApiConfiguration.Configure();

            //app.UseCors(Microsoft.Owin.Cors.CorsOptions.AllowAll);
            ConfigureOAuth(app);
        }
Пример #6
0
        protected void Application_Start()
        {
            GlobalConfiguration.Configuration.Formatters.JsonFormatter.SerializerSettings.Culture = new CultureInfo(string.Empty)
            {
                NumberFormat = new NumberFormatInfo
                {
                    CurrencyDecimalDigits = 5
                }
            };

            AreaRegistration.RegisterAllAreas();
            GlobalConfiguration.Configure(WebApiConfig.Register);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);

            AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
        }
 protected void Application_Start()
 {
     GlobalConfiguration.Configure(WebApiConfig.Register);
     AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
 }
Пример #8
0
 protected void Application_Start()
 {
     AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
     GlobalConfiguration.Configure(WebApiConfig.Register);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
 }
Пример #9
0
        public static void Run()

        {
            AutofacWebApiConfig.Initialize(GlobalConfiguration.Configuration);
        }