Esempio n. 1
0
 protected void Application_Start()
 {
     AreaRegistration.RegisterAllAreas();
     var c = new RestfulMVC();
     c.Init();
     ModelBinders.Binders.DefaultBinder = new RestfulDefaultModelBinder();
     RegisterRoutes(RouteTable.Routes);
 }
Esempio n. 2
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            var c = new RestfulMVC();
            c.Init();
            ModelBinders.Binders.DefaultBinder = new RestfulDefaultModelBinder();
            RegisterRoutes(RouteTable.Routes);

            try
            {
                AutoMapperConfiguration.Configure();
                Mapper.AssertConfigurationIsValid();
            }
            catch (Exception)
            {
                //Some mapping is not working
            }
        }