Add borders on college recommendation email

master
dan 2019-07-25 20:17:10 -06:00
parent 703a4bc505
commit ad4044e712
3 changed files with 15 additions and 3 deletions

View File

@ -12,6 +12,17 @@
tr.value > td {
border-bottom: 1px solid black;
}
table.border {
border-collapse: collapse;
}
table.border, table.border th, table.border td {
border: 1px solid black;
}
table.border td {
padding: 5px;
}
</style>
<h3>Old Fashion Baptist Church Missionary Questionnaire</h3>

View File

@ -33,6 +33,7 @@ namespace OFBButte.Console
var env = appSettings.Environment;
try
{
//AddMissionarySupportForm();
await SendMissionarySupportForm();
}
catch (Exception ex)

View File

@ -70,10 +70,10 @@ namespace OFBButte.Entities
public Dictionary<string, string> ToDictionary()
{
var properties = GetType().GetProperties(System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.Public).ToDictionary(p => p.Name, p => p);
var properties = GetType().GetProperties(BindingFlags.Instance | BindingFlags.Public).ToDictionary(p => p.Name, p => p);
var props = properties.ToDictionary(p => p.Key, p => p.Value.GetValue(this)?.ToString() ?? "");
props.Add("ChildNames", string.Join("<br>", Children.Select(c => c.Name)));
StringBuilder colleges = new StringBuilder("<table><tbody>");
StringBuilder colleges = new StringBuilder("<table class=\"border\"><tbody>");
foreach (var college in CollegeRecommendations)
{
colleges.Append($"<tr><td>{college.Name}&nbsp;&nbsp;&nbsp;&nbsp;</td><td>{college.City}, {college.State}</td></tr>");
@ -92,7 +92,7 @@ namespace OFBButte.Entities
private void GenerateHtml()
{
var props = GetType().GetProperties(System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.Public).ToDictionary(p => p.Name, p => p.GetValue(this)?.ToString() ?? "");
var props = GetType().GetProperties(BindingFlags.Instance | BindingFlags.Public).ToDictionary(p => p.Name, p => p.GetValue(this)?.ToString() ?? "");
StringBuilder sb = new StringBuilder();
sb.AppendLine("<table>");
sb.AppendLine(" <tbody>");