Skip to content

Commit 90452a2

Browse files
improved html
1 parent 773b5e8 commit 90452a2

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

Modules/CIPPCore/Public/New-CIPPAlertTemplate.ps1

+2-3
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,14 @@ function New-CIPPAlertTemplate {
2929
}
3030
if ($InputObject -eq 'standards') {
3131
$DataHTML = foreach ($object in $data) {
32-
"<p>For the standard $($object.standardName) in template {{Template Name }} we've detected the following:</p> <li>$($object.message)</li>"
32+
"<p>For the standard $($object.standardName) we've detected the following:</p> <li>$($object.message)</li>"
3333
if ($object.object) {
3434
$StandardObject = $object.object | ConvertFrom-Json
35-
$StandardObject = $newobject | Select-Object * -ExcludeProperty Etag, PartitionKey, TimeStamp
35+
$StandardObject = $StandardObject | Select-Object * -ExcludeProperty Etag, PartitionKey, TimeStamp
3636
if ($StandardObject.compare) {
3737
'<p>The following differences have been detected:</p>'
3838
($StandardObject.compare | ConvertTo-Html -Fragment | Out-String).Replace('<table>', ' <table class="table-modern">')
3939
} else {
40-
'<p>This is a table representation of the current settings:</p>'
4140
($StandardObject | ConvertTo-Html -Fragment -As List | Out-String).Replace('<table>', ' <table class="table-modern">')
4241
}
4342
}

TemplateEmail.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747

4848
.table-modern {{
4949
width: 100%;
50+
table-layout: fixed;
5051
border-collapse: separate;
5152
border-spacing: 0;
5253
font-family: Arial, sans-serif;
@@ -56,7 +57,6 @@
5657
padding: 10px;
5758
text-align: left;
5859
border: 1px solid #e0e0e0;
59-
white-space: nowrap;
6060
}}
6161

6262
.table-modern tr:nth-child(even) {{

0 commit comments

Comments
 (0)