Use existing character variable.

This commit is contained in:
AaronKable 2020-05-14 17:05:01 +08:00
parent f1d5cc8903
commit ed4270a0e3

View File

@ -141,8 +141,7 @@
</table> </table>
<table class="table table-aa visible-xs-block" style="width: 100%"> <table class="table table-aa visible-xs-block" style="width: 100%">
<tbody> <tbody>
{% for ownership in request.user.character_ownerships.all %} {% for char in characters %}
{% with ownership.character as char %}
<tr> <tr>
<td class="text-center" style="vertical-align: middle"> <td class="text-center" style="vertical-align: middle">
<img class="ra-avatar img-circle" src="{{ char.portrait_url_32 }}"> <img class="ra-avatar img-circle" src="{{ char.portrait_url_32 }}">
@ -153,7 +152,6 @@
{{ char.alliance_name|default:"" }} {{ char.alliance_name|default:"" }}
</td> </td>
</tr> </tr>
{% endwith %}
{% endfor %} {% endfor %}
</tbody> </tbody>
</table> </table>