06/03 Optimize code
This commit is contained in:
@@ -197,7 +197,17 @@
|
||||
<div style="font-size:11px;color:var(--muted);">{{ acct.account_type | replace('_',' ') | title }}</div>
|
||||
</div>
|
||||
</div>
|
||||
{% if acct.account_type == 'credit_card' %}
|
||||
{% set cc_owed = [0, -acct.balance] | max %}
|
||||
<div class="text-end">
|
||||
<span class="mono {% if cc_owed > 0 %}text-expense{% else %}text-income{% endif %}" style="font-size:13px;font-weight:600;">
|
||||
{% if cc_owed > 0 %}-{% endif %}{{ cc_owed | currency }}
|
||||
</span>
|
||||
<div style="font-size:10px;color:var(--muted);">owed</div>
|
||||
</div>
|
||||
{% else %}
|
||||
<span class="mono {% if acct.balance >= 0 %}text-income{% else %}text-expense{% endif %}" style="font-size:13px;font-weight:600;">{{ acct.balance | currency }}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
<div class="mt-3 pt-1" style="font-size:12px;color:var(--muted);">
|
||||
|
||||
Reference in New Issue
Block a user