Пример #1
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            RouteConfig.RegisterRoutes(RouteTable.Routes);

            JsonSerializerSettings setting = new JsonSerializerSettings();

            JsonConvert.DefaultSettings = () =>
            {
                setting.DateFormatHandling = DateFormatHandling.MicrosoftDateFormat;
                setting.DateFormatString   = "yyyy-MM-dd HH:mm:ss";
                return(setting);
            };

            LogHelper.SetConfig(new System.IO.FileInfo(AppDomain.CurrentDomain.BaseDirectory + "log4net.config"));

            AutoMapperProfile.InitAllProfile();
        }