AutoMapper

This commit is contained in:
Stef Heyenrath
2021-07-25 15:26:50 +02:00
parent 3c9a292a0c
commit 2531e8e688
9 changed files with 264 additions and 96 deletions
@@ -94,16 +94,19 @@ namespace {symbol.ContainingNamespace}
//}
//else
var existing = _context.CandidateInterfaces.Values.FirstOrDefault(x => x.TypeName == property.Type.ToString());
if (existing is not null)
{
str.AppendLine($" {property.ToPropertyText(existing.InterfaceName)}");
}
else
{
str.AppendLine($" {property.ToPropertyText()}");
}
var type = GetPropertyType(property, out _);
str.AppendLine($" {property.ToPropertyText(type)}");
//var existing = _context.CandidateInterfaces.Values.FirstOrDefault(x => x.TypeName == property.Type.ToString());
//if (existing is not null)
//{
// str.AppendLine($" {property.ToPropertyText(existing.InterfaceName)}");
//}
//else
//{
// str.AppendLine($" {property.ToPropertyText()}");
//}
str.AppendLine();
}