Почему html не всегда выравнивает и не выравнивает фигуры в ячейках - PullRequest
0 голосов
/ 09 апреля 2019

enter image description here

<html>
<head>
<style> .inkclass {text-align: right;} </style>
</head>
<body>
<h3>Company Name</h3>
<table border = "1">
<tr>
<th>Group</th>
<th>Units</th>
<th>Selling Excl.</th>
<th>Cost Value</th>
<th>GP Value</th>
<th>GP %</th>
<th>Selling Incl.</th>
<th>Budget Value</th>
<th>Budget %</th>
</tr>

<tr>
<td>Group</td>
<td class="inkclass">10</td>
<td class="inkclass">2,892.00</td>
<td class="inkclass">1,055.56</td>
<td class="inkclass">1,836.44</td>
<td class="inkclass">63.50</td>
<td class="inkclass">3,325.80</td>
<td class="inkclass">180,000.00</td>
<td class="inkclass">1.61</td>
</tr>

В следующем HTML-коде, который генерируется запросом ms-sql, выходные данные являются согласованными. Однако, когда эти выходные данные отправляются по почте sql db с body_format = 'html', выравнивание и стиль рисунков в ячейках не отображаются согласованно (при просмотре в gmail), даже если каждый «td» имеет один и тот же класс.

EXEC msdb.dbo.sp_send_dbmail
@profile_name = 'such-and-such',
@recipients = 'xyz@gmail.com;',
@subject = 'whatever',
@body = '',
@body_format = 'html',
@query = 'the-query-name-is-here',
@execute_query_database = 'the-db',
@attach_query_result_as_file = 0
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...