|
1 | 1 | <#@ include file="EF.Reverse.POCO.Core.ttinclude" #> |
2 | 2 | <# |
3 | | - // v2.34.1 |
| 3 | + // v2.35.0 |
4 | 4 | // Please make changes to the settings below. |
5 | 5 | // All you have to do is save this file, and the output file(s) is/are generated. Compiling does not regenerate the file(s). |
6 | 6 | // A course for this generator is available on Pluralsight at https://www.pluralsight.com/courses/code-first-entity-framework-legacy-databases |
|
207 | 207 | // Column modification***************************************************************************************************************** |
208 | 208 | // Use the following list to replace column byte types with Enums. |
209 | 209 | // 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 |
212 | 212 |
|
213 | 213 | // Use the following function if you need to apply additional modifications to a column |
214 | 214 | // eg. normalise names etc. |
|
278 | 278 | { |
279 | 279 | if (Settings.IncludeExtendedPropertyComments != CommentsStyle.None && !string.IsNullOrEmpty(t.ExtendedProperty)) |
280 | 280 | { |
| 281 | + var lines = t.ExtendedProperty |
| 282 | + .Split(new string[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries) |
| 283 | + .ToList(); |
281 | 284 | 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 | + } |
283 | 289 | WriteLine(" ///</summary>"); |
284 | 290 | } |
285 | 291 | }; |
|
0 commit comments