Upgraded services to latest version of Petapoco

pull/3113/head
kay.one 13 years ago
parent ba43509a67
commit 04afa21b98

@ -1,8 +1,8 @@
using NzbDrone.Services.Service.Datastore;
using PetaPoco;
using Microsoft.Web.Infrastructure.DynamicModuleHelper;
using Ninject;
using Ninject.Web.Mvc;
using Services.PetaPoco;
[assembly: WebActivator.PreApplicationStartMethod(typeof(NzbDrone.Services.Service.App_Start.NinjectMVC3), "Start")]
[assembly: WebActivator.ApplicationShutdownMethodAttribute(typeof(NzbDrone.Services.Service.App_Start.NinjectMVC3), "Stop")]

@ -3,7 +3,7 @@ using System.Linq;
using System.Web.Mvc;
using NzbDrone.Common;
using NzbDrone.Core.Datastore.Migrations;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Controllers
{

@ -5,7 +5,7 @@ using NLog;
using NzbDrone.Common;
using NzbDrone.Common.Contract;
using NzbDrone.Services.Service.Repository.Reporting;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Controllers
@ -42,7 +42,7 @@ namespace NzbDrone.Services.Service.Controllers
private bool ParseErrorExists(string title)
{
return _database.Exists<ParseErrorRow>("WHERE Title = @0", title);
return _database.Exists<ParseErrorRow>(title);
}
[HttpPost]
@ -61,12 +61,12 @@ namespace NzbDrone.Services.Service.Controllers
return Json(OK);
}
catch(Exception)
catch (Exception)
{
logger.Trace(exceptionReport.NullCheck());
throw;
}
}
}
}

@ -1,7 +1,10 @@
using System.Configuration;
using System;
using System.Configuration;
using System.Data.SqlClient;
using System.Linq;
using NzbDrone.Services.Service.Migrations;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Datastore
{
@ -16,7 +19,7 @@ namespace NzbDrone.Services.Service.Datastore
{
MigrationsHelper.Run(GetConnectionString);
var db = new Database("SqlExpress")
{
KeepConnectionAlive = true,

@ -110,6 +110,7 @@
<ItemGroup>
<Compile Include="App_Start\Logging.cs" />
<Compile Include="App_Start\NinjectMVC3.cs" />
<Compile Include="Services.PetaPoco.cs" />
<Compile Include="Datastore\Connection.cs" />
<Compile Include="Controllers\DailySeriesController.cs" />
<Compile Include="Controllers\HealthController.cs" />

@ -3,7 +3,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Web;
using NzbDrone.Services.Service.Repository;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Providers
{

@ -3,7 +3,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Web;
using NzbDrone.Services.Service.Repository;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Providers
{

@ -2,7 +2,8 @@
using System.Collections.Generic;
using System.Linq;
using System.Web;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Repository
{

@ -2,7 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Web;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Repository
{

@ -1,5 +1,5 @@
using System.Linq;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Repository.Reporting
{

@ -1,9 +1,11 @@
using System.Linq;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Repository.Reporting
{
[TableName("ParseErrorReports")]
[PrimaryKey("Title", autoIncrement = false)]
public class ParseErrorRow : ReportRowBase
{
public string Title { get; set; }

@ -2,7 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Web;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Repository
{

@ -7,7 +7,8 @@ using Migrator.Providers.SqlServer;
using NzbDrone.Services.Service.Migrations;
using NzbDrone.Test.Common;
using NzbDrone.Test.Common.AutoMoq;
using PetaPoco;
using Services.PetaPoco;
namespace NzbDrone.Services.Tests.Framework
{

Loading…
Cancel
Save