Publish to Sound Press dev ops
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<UserSecretsId>f9e2fd37-0f2d-4e3a-955a-8e49a16fce1c</UserSecretsId>
|
||||
<Configurations>Debug;Release;Also Debug</Configurations>
|
||||
<SatelliteResourceLanguages>en-us;en</SatelliteResourceLanguages>
|
||||
@@ -30,18 +30,16 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="11.0.0" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="6.0.5" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Razor.Design" Version="2.2.0" PrivateAssets="All" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="6.0.5" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="8.0.24" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Razor.Design" Version="2.3.0" PrivateAssets="All" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="8.0.23" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
||||
<PackageReference Include="Ratermania.Shopify" Version="6.16.11" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.3.1" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.ReDoc" Version="6.3.1" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="10.1.3" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.ReDoc" Version="8.1.4" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\ratermania\Packages\Shopify\Shopify.csproj" />
|
||||
<ProjectReference Include="..\PartSource.Data\PartSource.Data.csproj" />
|
||||
<ProjectReference Include="..\PartSource.Services\PartSource.Services.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -5,7 +5,7 @@ using Microsoft.AspNetCore.Mvc.Formatters;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.OpenApi.Models;
|
||||
using Microsoft.OpenApi;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Serialization;
|
||||
using PartSource.Data.Contexts;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Configurations>Debug;Release;Also Debug</Configurations>
|
||||
<ServerGarbageCollection>true</ServerGarbageCollection>
|
||||
</PropertyGroup>
|
||||
@@ -12,19 +12,17 @@
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="6.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="6.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Hosting" Version="6.0.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="6.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="8.0.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Hosting" Version="8.0.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="8.0.1" />
|
||||
<PackageReference Include="Ratermania.Automation" Version="6.16.9" />
|
||||
<PackageReference Include="Ratermania.Automation.Common" Version="6.16.9" />
|
||||
<PackageReference Include="Ratermania.JwtSpot" Version="6.16.9" />
|
||||
<PackageReference Include="System.Data.SqlClient" Version="4.8.5" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\ratermania\Packages\Shopify\Shopify.csproj" />
|
||||
<ProjectReference Include="..\PartSource.Data\PartSource.Data.csproj" />
|
||||
<ProjectReference Include="..\PartSource.Services\PartSource.Services.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using PartSource.Data.Contexts;
|
||||
using PartSource.Data.Dtos;
|
||||
using PartSource.Data.Models;
|
||||
|
||||
namespace PartSource.Automation.Services
|
||||
|
||||
@@ -1,16 +1,13 @@
|
||||
#pragma warning disable CA2100 // Review SQL queries for security vulnerabilities
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using Microsoft.Data.SqlClient;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using PartSource.Automation.Models.Configuration;
|
||||
using PartSource.Automation.Models.Enums;
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Data.SqlClient;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PartSource.Automation.Services
|
||||
{
|
||||
@@ -36,7 +33,7 @@ namespace PartSource.Automation.Services
|
||||
|
||||
// WHI changed the transfer protocol to SFTP and then messed with the directory structure.
|
||||
// Since fitment isn't really all that automated anyway, just download the files manually with an SFTP client.
|
||||
Console.WriteLine($"Remember to manually download the {seoDataTypeString} files with an SFTP client. Press any key to continue.");
|
||||
Console.WriteLine($"Remember to manually download the {seoDataTypeString} files with an SFTP client. Press enter to continue.");
|
||||
Console.ReadLine();
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Configurations>Debug;Release;Also Debug</Configurations>
|
||||
</PropertyGroup>
|
||||
|
||||
@@ -17,12 +17,12 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="6.0.5">
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="8.0.24">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="6.0.5" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.24" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Configurations>Debug;Release;Also Debug</Configurations>
|
||||
</PropertyGroup>
|
||||
|
||||
@@ -12,12 +12,10 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AutoMapper" Version="11.0.1" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\ratermania\Packages\Shopify\Shopify.csproj" />
|
||||
<ProjectReference Include="..\PartSource.Data\PartSource.Data.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
@@ -1,27 +1,22 @@
|
||||
using AutoMapper;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using PartSource.Data;
|
||||
using PartSource.Data.Contexts;
|
||||
using PartSource.Data.Dtos;
|
||||
using PartSource.Data.Models;
|
||||
using PartSource.Services.Extensions;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
||||
namespace PartSource.Services
|
||||
{
|
||||
public class VehicleService
|
||||
{
|
||||
private readonly IMapper _mapper;
|
||||
private readonly PartSourceContext _partSourceContext;
|
||||
|
||||
public VehicleService(IMapper mapper, PartSourceContext partSourceContext)
|
||||
public VehicleService(PartSourceContext partSourceContext)
|
||||
{
|
||||
_mapper = mapper;
|
||||
_partSourceContext = partSourceContext;
|
||||
}
|
||||
|
||||
@@ -59,7 +54,11 @@ namespace PartSource.Services
|
||||
.Where(v => v.MakeId == makeId)
|
||||
.FirstOrDefaultAsync();
|
||||
|
||||
return _mapper.Map<MakeDto>(vehicle);
|
||||
return new MakeDto
|
||||
{
|
||||
MakeId = vehicle.MakeId,
|
||||
MakeName = vehicle.MakeName
|
||||
};
|
||||
}
|
||||
|
||||
public async Task<IList<ModelDto>> GetModels(VehicleDto vehicleQuery)
|
||||
@@ -84,7 +83,13 @@ namespace PartSource.Services
|
||||
.Where(m => m.ModelId == modelId)
|
||||
.FirstOrDefaultAsync();
|
||||
|
||||
return _mapper.Map<ModelDto>(vehicle);
|
||||
return new ModelDto
|
||||
{
|
||||
MakeId = vehicle.MakeId,
|
||||
MakeName = vehicle.MakeName,
|
||||
ModelId = vehicle.ModelId,
|
||||
ModelName = vehicle.ModelName
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -111,7 +116,15 @@ namespace PartSource.Services
|
||||
.Where(b => b.BaseVehicleId == baseVehicleId)
|
||||
.FirstOrDefaultAsync();
|
||||
|
||||
return _mapper.Map<BaseVehicleDto>(vehicle);
|
||||
return new BaseVehicleDto
|
||||
{
|
||||
MakeId = vehicle.MakeId,
|
||||
MakeName = vehicle.MakeName,
|
||||
ModelId = vehicle.ModelId,
|
||||
ModelName = vehicle.ModelName,
|
||||
Year = vehicle.Year,
|
||||
BaseVehicleId = vehicle.BaseVehicleId
|
||||
};
|
||||
}
|
||||
|
||||
public async Task<IList<EngineDto>> GetEngines(VehicleDto vehicleQuery)
|
||||
@@ -135,7 +148,13 @@ namespace PartSource.Services
|
||||
.Where(e => e.EngineConfigId == engineConfigId)
|
||||
.FirstOrDefaultAsync();
|
||||
|
||||
return _mapper.Map<EngineDto>(vehicle);
|
||||
return new EngineDto
|
||||
{
|
||||
MakeId = vehicle.MakeId,
|
||||
MakeName = vehicle.MakeName,
|
||||
EngineConfigId = vehicle.EngineConfigId,
|
||||
EngineDescription = vehicle.EngineDescription
|
||||
};
|
||||
}
|
||||
|
||||
public async Task<IList<SubmodelDto>> GetSubmodels(VehicleDto vehicleQuery)
|
||||
@@ -160,7 +179,13 @@ namespace PartSource.Services
|
||||
.Where(s => s.SubmodelId == submodelId)
|
||||
.FirstOrDefaultAsync();
|
||||
|
||||
return _mapper.Map<SubmodelDto>(vehicle);
|
||||
return new SubmodelDto {
|
||||
SubmodelName = vehicle.SubmodelName,
|
||||
SubmodelId = vehicle.SubmodelId,
|
||||
MakeId= vehicle.MakeId,
|
||||
MakeName = vehicle.MakeName
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#region Legacy API Support
|
||||
|
||||
@@ -11,10 +11,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PartSource.Services", "Part
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PartSource.Automation", "PartSource.Automation\PartSource.Automation.csproj", "{C85D675B-A76C-4F9C-9C57-1E063211C946}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Shopify", "..\ratermania\Packages\Shopify\Shopify.csproj", "{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Shopify.BulkUpdate", "..\ratermania\Packages\Shopify.BulkUpdate\Shopify.BulkUpdate.csproj", "{E9F85D14-D6A6-1412-E0E6-69D47766694A}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
@@ -73,30 +69,6 @@ Global
|
||||
{C85D675B-A76C-4F9C-9C57-1E063211C946}.Release|x64.Build.0 = Release|Any CPU
|
||||
{C85D675B-A76C-4F9C-9C57-1E063211C946}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{C85D675B-A76C-4F9C-9C57-1E063211C946}.Release|x86.Build.0 = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|x64.Build.0 = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{DBAE670D-D4DC-CF6C-0615-1026D17A92D0}.Release|x86.Build.0 = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|x64.Build.0 = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{E9F85D14-D6A6-1412-E0E6-69D47766694A}.Release|x86.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
Reference in New Issue
Block a user