mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-10 15:32:37 -07:00
fixed #412
This commit is contained in:
parent
5bda83bfdf
commit
8854dc23c7
4 changed files with 279 additions and 277 deletions
|
@ -1,179 +1,183 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
<ProjectGuid>{A930E2CF-79E2-45F9-B06A-9A719A254CE4}</ProjectGuid>
|
<ProjectGuid>{A930E2CF-79E2-45F9-B06A-9A719A254CE4}</ProjectGuid>
|
||||||
<OutputType>Library</OutputType>
|
<OutputType>Library</OutputType>
|
||||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||||
<RootNamespace>PlexRequests.UI.Tests</RootNamespace>
|
<RootNamespace>PlexRequests.UI.Tests</RootNamespace>
|
||||||
<AssemblyName>PlexRequests.UI.Tests</AssemblyName>
|
<AssemblyName>PlexRequests.UI.Tests</AssemblyName>
|
||||||
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
||||||
<FileAlignment>512</FileAlignment>
|
<FileAlignment>512</FileAlignment>
|
||||||
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
|
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
|
||||||
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
|
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
|
||||||
<ReferencePath>$(ProgramFiles)\Common Files\microsoft shared\VSTT\$(VisualStudioVersion)\UITestExtensionPackages</ReferencePath>
|
<ReferencePath>$(ProgramFiles)\Common Files\microsoft shared\VSTT\$(VisualStudioVersion)\UITestExtensionPackages</ReferencePath>
|
||||||
<IsCodedUITest>False</IsCodedUITest>
|
<IsCodedUITest>False</IsCodedUITest>
|
||||||
<TestProjectType>UnitTest</TestProjectType>
|
<TestProjectType>UnitTest</TestProjectType>
|
||||||
<TargetFrameworkProfile />
|
<TargetFrameworkProfile />
|
||||||
<NuGetPackageImportStamp>
|
<NuGetPackageImportStamp>
|
||||||
</NuGetPackageImportStamp>
|
</NuGetPackageImportStamp>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
<DebugType>full</DebugType>
|
<DebugType>full</DebugType>
|
||||||
<Optimize>false</Optimize>
|
<Optimize>false</Optimize>
|
||||||
<OutputPath>bin\Debug\</OutputPath>
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
<DebugType>pdbonly</DebugType>
|
<DebugType>pdbonly</DebugType>
|
||||||
<Optimize>true</Optimize>
|
<Optimize>true</Optimize>
|
||||||
<OutputPath>bin\Release\</OutputPath>
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
<DefineConstants>TRACE</DefineConstants>
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="CsQuery, Version=1.3.3.5, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="CsQuery, Version=1.3.3.5, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\CsQuery.1.3.3\lib\net40\CsQuery.dll</HintPath>
|
<HintPath>..\packages\CsQuery.1.3.3\lib\net40\CsQuery.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="FluentScheduler, Version=3.1.46.0, Culture=neutral, PublicKeyToken=b76503528a14ebd1, processorArchitecture=MSIL">
|
<Reference Include="FluentScheduler, Version=3.1.46.0, Culture=neutral, PublicKeyToken=b76503528a14ebd1, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\FluentScheduler.3.1.46\lib\net40\FluentScheduler.dll</HintPath>
|
<HintPath>..\packages\FluentScheduler.3.1.46\lib\net40\FluentScheduler.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="FluentValidation, Version=6.2.1.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="FluentValidation, Version=6.2.1.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\FluentValidation.6.2.1.0\lib\Net45\FluentValidation.dll</HintPath>
|
<HintPath>..\packages\FluentValidation.6.2.1.0\lib\Net45\FluentValidation.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="Moq, Version=4.2.1510.2205, Culture=neutral, PublicKeyToken=69f491c39445e920, processorArchitecture=MSIL">
|
<Reference Include="Moq, Version=4.2.1510.2205, Culture=neutral, PublicKeyToken=69f491c39445e920, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Moq.4.2.1510.2205\lib\net40\Moq.dll</HintPath>
|
<HintPath>..\packages\Moq.4.2.1510.2205\lib\net40\Moq.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Nancy, Version=1.4.2.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="Nancy, Version=1.4.2.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Nancy.1.4.3\lib\net40\Nancy.dll</HintPath>
|
<HintPath>..\packages\Nancy.1.4.3\lib\net40\Nancy.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Nancy.Testing, Version=1.4.1.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="Nancy.Linker, Version=0.3.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Nancy.Testing.1.4.1\lib\net40\Nancy.Testing.dll</HintPath>
|
<HintPath>..\packages\Nancy.Linker.0.3.1\lib\net40-Client\Nancy.Linker.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Nancy.Validation.FluentValidation, Version=1.4.1.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="Nancy.Testing, Version=1.4.1.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Nancy.Validation.FluentValidation.1.4.1\lib\net40\Nancy.Validation.FluentValidation.dll</HintPath>
|
<HintPath>..\packages\Nancy.Testing.1.4.1\lib\net40\Nancy.Testing.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Nancy.ViewEngines.Razor, Version=1.4.2.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="Nancy.Validation.FluentValidation, Version=1.4.1.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Nancy.Viewengines.Razor.1.4.3\lib\net40\Nancy.ViewEngines.Razor.dll</HintPath>
|
<HintPath>..\packages\Nancy.Validation.FluentValidation.1.4.1\lib\net40\Nancy.Validation.FluentValidation.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Newtonsoft.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
<Reference Include="Nancy.ViewEngines.Razor, Version=1.4.2.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Newtonsoft.Json.8.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
<HintPath>..\packages\Nancy.Viewengines.Razor.1.4.3\lib\net40\Nancy.ViewEngines.Razor.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="nunit.framework, Version=3.2.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
|
<Reference Include="Newtonsoft.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NUnit.3.2.0\lib\net45\nunit.framework.dll</HintPath>
|
<HintPath>..\packages\Newtonsoft.Json.8.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Ploeh.AutoFixture, Version=3.40.0.0, Culture=neutral, PublicKeyToken=b24654c590009d4f, processorArchitecture=MSIL">
|
<Reference Include="nunit.framework, Version=3.2.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\AutoFixture.3.40.0\lib\net40\Ploeh.AutoFixture.dll</HintPath>
|
<HintPath>..\packages\NUnit.3.2.0\lib\net45\nunit.framework.dll</HintPath>
|
||||||
<Private>True</Private>
|
<Private>True</Private>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="Ploeh.AutoFixture, Version=3.40.0.0, Culture=neutral, PublicKeyToken=b24654c590009d4f, processorArchitecture=MSIL">
|
||||||
<Reference Include="System.Web" />
|
<HintPath>..\packages\AutoFixture.3.40.0\lib\net40\Ploeh.AutoFixture.dll</HintPath>
|
||||||
<Reference Include="System.Web.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
|
<Private>True</Private>
|
||||||
<HintPath>..\packages\Microsoft.AspNet.Razor.2.0.30506.0\lib\net40\System.Web.Razor.dll</HintPath>
|
</Reference>
|
||||||
<Private>True</Private>
|
<Reference Include="System" />
|
||||||
</Reference>
|
<Reference Include="System.Web" />
|
||||||
</ItemGroup>
|
<Reference Include="System.Web.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
|
||||||
<Choose>
|
<HintPath>..\packages\Microsoft.AspNet.Razor.2.0.30506.0\lib\net40\System.Web.Razor.dll</HintPath>
|
||||||
<When Condition="('$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == '') and '$(TargetFrameworkVersion)' == 'v3.5'">
|
<Private>True</Private>
|
||||||
<ItemGroup>
|
</Reference>
|
||||||
<Reference Include="Microsoft.VisualStudio.QualityTools.UnitTestFramework, Version=10.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
|
</ItemGroup>
|
||||||
</ItemGroup>
|
<Choose>
|
||||||
</When>
|
<When Condition="('$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == '') and '$(TargetFrameworkVersion)' == 'v3.5'">
|
||||||
<Otherwise />
|
<ItemGroup>
|
||||||
</Choose>
|
<Reference Include="Microsoft.VisualStudio.QualityTools.UnitTestFramework, Version=10.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
|
||||||
<ItemGroup>
|
</ItemGroup>
|
||||||
<Compile Include="ApiModuleTests.cs" />
|
</When>
|
||||||
<Compile Include="BootstrapperExtensions.cs" />
|
<Otherwise />
|
||||||
<Compile Include="LandingPageTests.cs" />
|
</Choose>
|
||||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
<ItemGroup>
|
||||||
<Compile Include="StringHelperTests.cs" />
|
<Compile Include="ApiModuleTests.cs" />
|
||||||
<Compile Include="TestRootPathProvider.cs" />
|
<Compile Include="BootstrapperExtensions.cs" />
|
||||||
<Compile Include="UserLoginModuleTests.cs" />
|
<Compile Include="LandingPageTests.cs" />
|
||||||
<Compile Include="AdminModuleTests.cs" />
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
</ItemGroup>
|
<Compile Include="StringHelperTests.cs" />
|
||||||
<ItemGroup>
|
<Compile Include="TestRootPathProvider.cs" />
|
||||||
<None Include="app.config" />
|
<Compile Include="UserLoginModuleTests.cs" />
|
||||||
<None Include="packages.config" />
|
<Compile Include="AdminModuleTests.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\PlexRequests.Api.Interfaces\PlexRequests.Api.Interfaces.csproj">
|
<None Include="app.config" />
|
||||||
<Project>{95834072-A675-415D-AA8F-877C91623810}</Project>
|
<None Include="packages.config" />
|
||||||
<Name>PlexRequests.Api.Interfaces</Name>
|
</ItemGroup>
|
||||||
</ProjectReference>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\PlexRequests.Api.Models\PlexRequests.Api.Models.csproj">
|
<ProjectReference Include="..\PlexRequests.Api.Interfaces\PlexRequests.Api.Interfaces.csproj">
|
||||||
<Project>{CB37A5F8-6DFC-4554-99D3-A42B502E4591}</Project>
|
<Project>{95834072-A675-415D-AA8F-877C91623810}</Project>
|
||||||
<Name>PlexRequests.Api.Models</Name>
|
<Name>PlexRequests.Api.Interfaces</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\PlexRequests.Core\PlexRequests.Core.csproj">
|
<ProjectReference Include="..\PlexRequests.Api.Models\PlexRequests.Api.Models.csproj">
|
||||||
<Project>{DD7DC444-D3BF-4027-8AB9-EFC71F5EC581}</Project>
|
<Project>{CB37A5F8-6DFC-4554-99D3-A42B502E4591}</Project>
|
||||||
<Name>PlexRequests.Core</Name>
|
<Name>PlexRequests.Api.Models</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\PlexRequests.Helpers\PlexRequests.Helpers.csproj">
|
<ProjectReference Include="..\PlexRequests.Core\PlexRequests.Core.csproj">
|
||||||
<Project>{1252336d-42a3-482a-804c-836e60173dfa}</Project>
|
<Project>{DD7DC444-D3BF-4027-8AB9-EFC71F5EC581}</Project>
|
||||||
<Name>PlexRequests.Helpers</Name>
|
<Name>PlexRequests.Core</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\PlexRequests.Services\PlexRequests.Services.csproj">
|
<ProjectReference Include="..\PlexRequests.Helpers\PlexRequests.Helpers.csproj">
|
||||||
<Project>{566EFA49-68F8-4716-9693-A6B3F2624DEA}</Project>
|
<Project>{1252336d-42a3-482a-804c-836e60173dfa}</Project>
|
||||||
<Name>PlexRequests.Services</Name>
|
<Name>PlexRequests.Helpers</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\PlexRequests.Store\PlexRequests.Store.csproj">
|
<ProjectReference Include="..\PlexRequests.Services\PlexRequests.Services.csproj">
|
||||||
<Project>{92433867-2B7B-477B-A566-96C382427525}</Project>
|
<Project>{566EFA49-68F8-4716-9693-A6B3F2624DEA}</Project>
|
||||||
<Name>PlexRequests.Store</Name>
|
<Name>PlexRequests.Services</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\PlexRequests.UI\PlexRequests.UI.csproj">
|
<ProjectReference Include="..\PlexRequests.Store\PlexRequests.Store.csproj">
|
||||||
<Project>{68F5F5F3-B8BB-4911-875F-6F00AAE04EA6}</Project>
|
<Project>{92433867-2B7B-477B-A566-96C382427525}</Project>
|
||||||
<Name>PlexRequests.UI</Name>
|
<Name>PlexRequests.Store</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
<ProjectReference Include="..\PlexRequests.UI\PlexRequests.UI.csproj">
|
||||||
<Choose>
|
<Project>{68F5F5F3-B8BB-4911-875F-6F00AAE04EA6}</Project>
|
||||||
<When Condition="'$(VisualStudioVersion)' == '10.0' And '$(IsCodedUITest)' == 'True'">
|
<Name>PlexRequests.UI</Name>
|
||||||
<ItemGroup>
|
</ProjectReference>
|
||||||
<Reference Include="Microsoft.VisualStudio.QualityTools.CodedUITestFramework, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
</ItemGroup>
|
||||||
<Private>False</Private>
|
<Choose>
|
||||||
</Reference>
|
<When Condition="'$(VisualStudioVersion)' == '10.0' And '$(IsCodedUITest)' == 'True'">
|
||||||
<Reference Include="Microsoft.VisualStudio.TestTools.UITest.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
<ItemGroup>
|
||||||
<Private>False</Private>
|
<Reference Include="Microsoft.VisualStudio.QualityTools.CodedUITestFramework, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||||
</Reference>
|
<Private>False</Private>
|
||||||
<Reference Include="Microsoft.VisualStudio.TestTools.UITest.Extension, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
</Reference>
|
||||||
<Private>False</Private>
|
<Reference Include="Microsoft.VisualStudio.TestTools.UITest.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||||
</Reference>
|
<Private>False</Private>
|
||||||
<Reference Include="Microsoft.VisualStudio.TestTools.UITesting, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
</Reference>
|
||||||
<Private>False</Private>
|
<Reference Include="Microsoft.VisualStudio.TestTools.UITest.Extension, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||||
</Reference>
|
<Private>False</Private>
|
||||||
</ItemGroup>
|
</Reference>
|
||||||
</When>
|
<Reference Include="Microsoft.VisualStudio.TestTools.UITesting, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||||
</Choose>
|
<Private>False</Private>
|
||||||
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
|
</Reference>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
</ItemGroup>
|
||||||
<Import Project="..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets" Condition="Exists('..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets')" />
|
</When>
|
||||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
</Choose>
|
||||||
<PropertyGroup>
|
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
|
||||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
</PropertyGroup>
|
<Import Project="..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets" Condition="Exists('..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets')" />
|
||||||
<Error Condition="!Exists('..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets'))" />
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
</Target>
|
<PropertyGroup>
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
</PropertyGroup>
|
||||||
<Target Name="BeforeBuild">
|
<Error Condition="!Exists('..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Nancy.Viewengines.Razor.1.4.3\build\Nancy.ViewEngines.Razor.targets'))" />
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="AfterBuild">
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
</Target>
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
-->
|
<Target Name="BeforeBuild">
|
||||||
|
</Target>
|
||||||
|
<Target Name="AfterBuild">
|
||||||
|
</Target>
|
||||||
|
-->
|
||||||
</Project>
|
</Project>
|
|
@ -1,15 +1,16 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="AutoFixture" version="3.40.0" targetFramework="net452" />
|
<package id="AutoFixture" version="3.40.0" targetFramework="net452" />
|
||||||
<package id="CsQuery" version="1.3.3" targetFramework="net46" />
|
<package id="CsQuery" version="1.3.3" targetFramework="net46" />
|
||||||
<package id="FluentScheduler" version="3.1.46" targetFramework="net46" />
|
<package id="FluentScheduler" version="3.1.46" targetFramework="net46" />
|
||||||
<package id="FluentValidation" version="6.2.1.0" targetFramework="net46" />
|
<package id="FluentValidation" version="6.2.1.0" targetFramework="net46" />
|
||||||
<package id="Microsoft.AspNet.Razor" version="2.0.30506.0" targetFramework="net46" />
|
<package id="Microsoft.AspNet.Razor" version="2.0.30506.0" targetFramework="net46" />
|
||||||
<package id="Moq" version="4.2.1510.2205" targetFramework="net452" />
|
<package id="Moq" version="4.2.1510.2205" targetFramework="net452" />
|
||||||
<package id="Nancy" version="1.4.3" targetFramework="net46" />
|
<package id="Nancy" version="1.4.3" targetFramework="net46" />
|
||||||
<package id="Nancy.Testing" version="1.4.1" targetFramework="net46" />
|
<package id="Nancy.Linker" version="0.3.1" targetFramework="net46" />
|
||||||
<package id="Nancy.Validation.FluentValidation" version="1.4.1" targetFramework="net46" />
|
<package id="Nancy.Testing" version="1.4.1" targetFramework="net46" />
|
||||||
<package id="Nancy.Viewengines.Razor" version="1.4.3" targetFramework="net46" />
|
<package id="Nancy.Validation.FluentValidation" version="1.4.1" targetFramework="net46" />
|
||||||
<package id="Newtonsoft.Json" version="8.0.2" targetFramework="net46" />
|
<package id="Nancy.Viewengines.Razor" version="1.4.3" targetFramework="net46" />
|
||||||
<package id="NUnit" version="3.2.0" targetFramework="net46" />
|
<package id="Newtonsoft.Json" version="8.0.2" targetFramework="net46" />
|
||||||
|
<package id="NUnit" version="3.2.0" targetFramework="net46" />
|
||||||
</packages>
|
</packages>
|
|
@ -1,49 +1,81 @@
|
||||||
#region Copyright
|
#region Copyright
|
||||||
// /************************************************************************
|
// /************************************************************************
|
||||||
// Copyright (c) 2016 Jamie Rees
|
// Copyright (c) 2016 Jamie Rees
|
||||||
// File: IndexModule.cs
|
// File: IndexModule.cs
|
||||||
// Created By: Jamie Rees
|
// Created By: Jamie Rees
|
||||||
//
|
//
|
||||||
// Permission is hereby granted, free of charge, to any person obtaining
|
// Permission is hereby granted, free of charge, to any person obtaining
|
||||||
// a copy of this software and associated documentation files (the
|
// a copy of this software and associated documentation files (the
|
||||||
// "Software"), to deal in the Software without restriction, including
|
// "Software"), to deal in the Software without restriction, including
|
||||||
// without limitation the rights to use, copy, modify, merge, publish,
|
// without limitation the rights to use, copy, modify, merge, publish,
|
||||||
// distribute, sublicense, and/or sell copies of the Software, and to
|
// distribute, sublicense, and/or sell copies of the Software, and to
|
||||||
// permit persons to whom the Software is furnished to do so, subject to
|
// permit persons to whom the Software is furnished to do so, subject to
|
||||||
// the following conditions:
|
// the following conditions:
|
||||||
//
|
//
|
||||||
// The above copyright notice and this permission notice shall be
|
// The above copyright notice and this permission notice shall be
|
||||||
// included in all copies or substantial portions of the Software.
|
// included in all copies or substantial portions of the Software.
|
||||||
//
|
//
|
||||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||||
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||||
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||||
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
||||||
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||||
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||||
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
// ************************************************************************/
|
// ************************************************************************/
|
||||||
#endregion
|
#endregion
|
||||||
using Nancy.Extensions;
|
using System.Threading.Tasks;
|
||||||
using Nancy.Responses;
|
|
||||||
|
using Nancy;
|
||||||
using PlexRequests.Core;
|
using Nancy.Extensions;
|
||||||
using PlexRequests.Core.SettingModels;
|
using Nancy.Linker;
|
||||||
|
using Nancy.Responses;
|
||||||
namespace PlexRequests.UI.Modules
|
|
||||||
{
|
using PlexRequests.Core;
|
||||||
public class IndexModule : BaseAuthModule
|
using PlexRequests.Core.SettingModels;
|
||||||
{
|
|
||||||
public IndexModule(ISettingsService<PlexRequestSettings> pr) : base(pr)
|
namespace PlexRequests.UI.Modules
|
||||||
{
|
{
|
||||||
Get["/"] = x => Index();
|
public class IndexModule : BaseAuthModule
|
||||||
|
{
|
||||||
Get["/Index"] = x => Index();
|
public IndexModule(ISettingsService<PlexRequestSettings> pr, ISettingsService<LandingPageSettings> l, IResourceLinker rl) : base(pr)
|
||||||
}
|
{
|
||||||
|
LandingPage = l;
|
||||||
public RedirectResponse Index()
|
Linker = rl;
|
||||||
{
|
Get["Index", "/", true] = async (x, ct) => await Index();
|
||||||
return Context.GetRedirect(!string.IsNullOrEmpty(BaseUrl) ? $"~/{BaseUrl}/search" : "~/search");
|
|
||||||
}
|
Get["/Index", true] = async (x, ct) => await Index();
|
||||||
}
|
}
|
||||||
|
private ISettingsService<LandingPageSettings> LandingPage { get; }
|
||||||
|
private IResourceLinker Linker { get; }
|
||||||
|
|
||||||
|
public async Task<RedirectResponse> Index()
|
||||||
|
{
|
||||||
|
var settings = await LandingPage.GetSettingsAsync();
|
||||||
|
if (settings.Enabled)
|
||||||
|
{
|
||||||
|
if (settings.BeforeLogin) // Before login
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(Username))
|
||||||
|
{
|
||||||
|
// They are not logged in
|
||||||
|
return Context.GetRedirect(Linker.BuildAbsoluteUri(Context, "LandingPageIndex").ToString());
|
||||||
|
}
|
||||||
|
return Context.GetRedirect(Linker.BuildAbsoluteUri(Context, "SearchIndex").ToString());
|
||||||
|
}
|
||||||
|
|
||||||
|
// After login
|
||||||
|
if (string.IsNullOrEmpty(Username))
|
||||||
|
{
|
||||||
|
// Not logged in yet
|
||||||
|
return Context.GetRedirect(Linker.BuildAbsoluteUri(Context, "UserLoginIndex").ToString());
|
||||||
|
}
|
||||||
|
// Send them to landing
|
||||||
|
var landingUrl = Linker.BuildAbsoluteUri(Context, "LandingPageIndex").ToString();
|
||||||
|
return Context.GetRedirect(landingUrl);
|
||||||
|
}
|
||||||
|
|
||||||
|
return Context.GetRedirect(Linker.BuildAbsoluteUri(Context, "UserLoginIndex").ToString());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -55,7 +55,7 @@ namespace PlexRequests.UI.Modules
|
||||||
LandingPageSettings = lp;
|
LandingPageSettings = lp;
|
||||||
Analytics = a;
|
Analytics = a;
|
||||||
Api = api;
|
Api = api;
|
||||||
Get["/", true] = async (x, ct) => await Index();
|
Get["UserLoginIndex","/", true] = async (x, ct) => await Index();
|
||||||
Post["/"] = x => LoginUser();
|
Post["/"] = x => LoginUser();
|
||||||
Get["/logout"] = x => Logout();
|
Get["/logout"] = x => Logout();
|
||||||
}
|
}
|
||||||
|
@ -69,42 +69,7 @@ namespace PlexRequests.UI.Modules
|
||||||
|
|
||||||
public async Task<Negotiator> Index()
|
public async Task<Negotiator> Index()
|
||||||
{
|
{
|
||||||
var query = Request.Query["landing"];
|
|
||||||
var landingCheck = (bool?)query ?? true;
|
|
||||||
if (landingCheck)
|
|
||||||
{
|
|
||||||
var landingSettings = await LandingPageSettings.GetSettingsAsync();
|
|
||||||
|
|
||||||
if (landingSettings.Enabled)
|
|
||||||
{
|
|
||||||
|
|
||||||
if (landingSettings.BeforeLogin)
|
|
||||||
{
|
|
||||||
#pragma warning disable 4014
|
|
||||||
Analytics.TrackEventAsync(
|
|
||||||
#pragma warning restore 4014
|
|
||||||
Category.LandingPage,
|
|
||||||
Action.View,
|
|
||||||
"Going To LandingPage before login",
|
|
||||||
Username,
|
|
||||||
CookieHelper.GetAnalyticClientId(Cookies));
|
|
||||||
|
|
||||||
var model = new LandingPageViewModel
|
|
||||||
{
|
|
||||||
Enabled = landingSettings.Enabled,
|
|
||||||
Id = landingSettings.Id,
|
|
||||||
EnabledNoticeTime = landingSettings.EnabledNoticeTime,
|
|
||||||
NoticeEnable = landingSettings.NoticeEnable,
|
|
||||||
NoticeEnd = landingSettings.NoticeEnd,
|
|
||||||
NoticeMessage = landingSettings.NoticeMessage,
|
|
||||||
NoticeStart = landingSettings.NoticeStart,
|
|
||||||
ContinueUrl = landingSettings.BeforeLogin ? $"userlogin" : $"search"
|
|
||||||
};
|
|
||||||
|
|
||||||
return View["Landing/Index", model];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
var settings = await AuthService.GetSettingsAsync();
|
var settings = await AuthService.GetSettingsAsync();
|
||||||
return View["Index", settings];
|
return View["Index", settings];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue