Skip to content

Commit 86ffe1a

Browse files
committed
sync sql ce settings
1 parent b217dd9 commit 86ffe1a

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

EntityFramework.Reverse.POCO.Generator/Database NorthwindSqlCe40.tt

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<#@ include file="EF.Reverse.POCO.Core.ttinclude" #>
22
<#
3-
// v2.34.1
3+
// v2.35.0
44
// Please make changes to the settings below.
55
// All you have to do is save this file, and the output file(s) is/are generated. Compiling does not regenerate the file(s).
66
// A course for this generator is available on Pluralsight at https://www.pluralsight.com/courses/code-first-entity-framework-legacy-databases
@@ -207,8 +207,8 @@
207207
// Column modification*****************************************************************************************************************
208208
// Use the following list to replace column byte types with Enums.
209209
// As long as the type can be mapped to your new type, all is well.
210-
//EnumsDefinitions.Add(new EnumDefinition { Schema = "dbo", Table = "match_table_name", Column = "match_column_name", EnumType = "name_of_enum" });
211-
//EnumsDefinitions.Add(new EnumDefinition { Schema = "dbo", Table = "OrderHeader", Column = "OrderStatus", EnumType = "OrderStatusType" }); // This will replace OrderHeader.OrderStatus type to be an OrderStatusType enum
210+
//Settings.EnumsDefinitions.Add(new EnumDefinition { Schema = "dbo", Table = "match_table_name", Column = "match_column_name", EnumType = "name_of_enum" });
211+
//Settings.EnumsDefinitions.Add(new EnumDefinition { Schema = "dbo", Table = "OrderHeader", Column = "OrderStatus", EnumType = "OrderStatusType" }); // This will replace OrderHeader.OrderStatus type to be an OrderStatusType enum
212212

213213
// Use the following function if you need to apply additional modifications to a column
214214
// eg. normalise names etc.
@@ -278,8 +278,14 @@
278278
{
279279
if (Settings.IncludeExtendedPropertyComments != CommentsStyle.None && !string.IsNullOrEmpty(t.ExtendedProperty))
280280
{
281+
var lines = t.ExtendedProperty
282+
.Split(new string[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries)
283+
.ToList();
281284
WriteLine(" ///<summary>");
282-
WriteLine(" /// {0}", System.Security.SecurityElement.Escape(t.ExtendedProperty));
285+
foreach(var line in lines)
286+
{
287+
WriteLine(" /// {0}", System.Security.SecurityElement.Escape(line));
288+
}
283289
WriteLine(" ///</summary>");
284290
}
285291
};

0 commit comments

Comments
 (0)