使用 contextual classes 将以下颜色添加到行中:
First row green
Second row red
Last row blue
<table class="table">
<tr class="@(7)">
<td>John</td>
<td>Doe</td>
<td>john@example.com</td>
<tr>
<tr class="@(6)">
<td>Mary</td>
<td>Moe</td>
<td>mary@example.com</td>
</tr>
<tr class="@(4)">
<td>July</td>
<td>Dooley</td>
<td>july@example.com</td>
</tr>
</table>
<table class="table">
<tr class="success">
<td>John</td>
<td>Doe</td>
<td>john@example.com</td>
<tr>
<tr class="danger">
<td>Mary</td>
<td>Moe</td>
<td>mary@example.com</td>
</tr>
<tr class="info">
<td>July</td>
<td>Dooley</td>
<td>july@example.com</td>
</tr>
</table>