Upgraded to MVC3, Hello Razor.

This commit is contained in:
kay.one 2011-03-29 23:18:35 -07:00
commit ff75d0c555
431 changed files with 10354 additions and 19744 deletions

View file

@ -1,5 +1,6 @@
using System;
using System.Diagnostics;
using System.Reflection;
using System.Threading;
using System.Web;
using System.Web.Mvc;
@ -32,22 +33,34 @@ namespace NzbDrone.Web
protected override void OnApplicationStarted()
{
base.OnApplicationStarted();
LogConfiguration.Setup();
Logger.Info("NZBDrone Starting up.");
CentralDispatch.DedicateToHost();
AreaRegistration.RegisterAllAreas();
RegisterRoutes(RouteTable.Routes);
base.OnApplicationStarted();
//base.OnApplicationStarted();
AreaRegistration.RegisterAllAreas();
RegisterGlobalFilters(GlobalFilters.Filters);
//RegisterRoutes(RouteTable.Routes);
}
protected override IKernel CreateKernel()
{
var kernel = CentralDispatch.NinjectKernel;
// kernel.Bind<IRepository>().ToConstant(kernel.Get<IRepository>("LogDb"));
// kernel.Bind<IRepository>().ToConstant(kernel.Get<IRepository>("LogDb"));
kernel.Load(Assembly.GetExecutingAssembly());
return kernel;
}
public static void RegisterGlobalFilters(GlobalFilterCollection filters)
{
filters.Add(new HandleErrorAttribute());
}
// ReSharper disable InconsistentNaming
protected void Application_Error(object sender, EventArgs e)
{