From 7a134148535a72bb7542aa2f5437a6a6c6d011fc Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Tue, 22 Aug 2017 12:38:48 -0400 Subject: [PATCH] local dapper build --- bitwarden-core.sln | 7 +++++++ src/Core/Core.csproj | 7 +++++-- src/Core/Utilities/CoreHelpers.cs | 5 +++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/bitwarden-core.sln b/bitwarden-core.sln index 2fa5c3466..0e8fbe4a3 100644 --- a/bitwarden-core.sln +++ b/bitwarden-core.sln @@ -39,6 +39,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Server", "util\Server\Serve EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Jobs", "src\Jobs\Jobs.csproj", "{7DCEBD8F-E5F3-4A3C-BD35-B64341590B74}" EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Dapper", "..\Dapper\Dapper\Dapper.csproj", "{6951E73D-1761-41F6-B5D3-BEF4C2F73EA3}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -83,6 +85,10 @@ Global {7DCEBD8F-E5F3-4A3C-BD35-B64341590B74}.Debug|Any CPU.Build.0 = Debug|Any CPU {7DCEBD8F-E5F3-4A3C-BD35-B64341590B74}.Release|Any CPU.ActiveCfg = Release|Any CPU {7DCEBD8F-E5F3-4A3C-BD35-B64341590B74}.Release|Any CPU.Build.0 = Release|Any CPU + {6951E73D-1761-41F6-B5D3-BEF4C2F73EA3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {6951E73D-1761-41F6-B5D3-BEF4C2F73EA3}.Debug|Any CPU.Build.0 = Debug|Any CPU + {6951E73D-1761-41F6-B5D3-BEF4C2F73EA3}.Release|Any CPU.ActiveCfg = Release|Any CPU + {6951E73D-1761-41F6-B5D3-BEF4C2F73EA3}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -97,6 +103,7 @@ Global {EF2164EF-1FC0-4518-A2ED-CE02D3630B00} = {DD5BD056-4AAE-43EF-BBD2-0B569B8DA84E} {66B0A682-658A-4A82-B606-A077A4871448} = {DD5BD056-4AAE-43EF-BBD2-0B569B8DA84E} {7DCEBD8F-E5F3-4A3C-BD35-B64341590B74} = {DD5BD056-4AAE-43EF-BBD2-0B569B8DA84D} + {6951E73D-1761-41F6-B5D3-BEF4C2F73EA3} = {DD5BD056-4AAE-43EF-BBD2-0B569B8DA84D} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {E01CBF68-2E20-425F-9EDB-E0A6510CA92F} diff --git a/src/Core/Core.csproj b/src/Core/Core.csproj index 02ad29616..4e1954ba2 100644 --- a/src/Core/Core.csproj +++ b/src/Core/Core.csproj @@ -59,7 +59,6 @@ - @@ -85,7 +84,11 @@ - + + + + + diff --git a/src/Core/Utilities/CoreHelpers.cs b/src/Core/Utilities/CoreHelpers.cs index f32159e06..9f7ba6e37 100644 --- a/src/Core/Utilities/CoreHelpers.cs +++ b/src/Core/Utilities/CoreHelpers.cs @@ -10,6 +10,7 @@ using System.Security.Cryptography; using System.Security.Cryptography.X509Certificates; using System.Text; using System.Text.RegularExpressions; +using Dapper; namespace Bit.Core.Utilities { @@ -58,8 +59,8 @@ namespace Bit.Core.Utilities public static DataTable ToArrayTVP(this IEnumerable values, string columnName) { var table = new DataTable(); + table.SetTypeName($"[dbo].[{columnName}Array]"); table.Columns.Add(columnName, typeof(T)); - table.ExtendedProperties["dapper:TypeName"] = $"[dbo].[{columnName}Array]"; if(values != null) { @@ -75,7 +76,7 @@ namespace Bit.Core.Utilities public static DataTable ToArrayTVP(this IEnumerable values) { var table = new DataTable(); - table.ExtendedProperties["dapper:TypeName"] = "[dbo].[SelectionReadOnlyArray]"; + table.SetTypeName("[dbo].[SelectionReadOnlyArray]"); var idColumn = new DataColumn("Id", typeof(Guid)); table.Columns.Add(idColumn);