Exemplo n.º 1
0
 protected void Application_Start()
 {
     AreaRegistration.RegisterAllAreas();
     var c = new RestfulMVC();
     c.Init();
     ModelBinders.Binders.DefaultBinder = new RestfulDefaultModelBinder();
     RegisterRoutes(RouteTable.Routes);
 }
Exemplo 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
            }
        }