This should fix #482

This commit is contained in:
James Cole 2016-12-20 17:10:30 +01:00
parent 304cdabc96
commit 8aa2961c19
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E
2 changed files with 4 additions and 3 deletions

View File

@ -221,6 +221,7 @@ class AccountController extends Controller
$account->lastActivityDate = $this->isInArray($activities, $account->id); $account->lastActivityDate = $this->isInArray($activities, $account->id);
$account->startBalance = $this->isInArray($startBalances, $account->id); $account->startBalance = $this->isInArray($startBalances, $account->id);
$account->endBalance = $this->isInArray($endBalances, $account->id); $account->endBalance = $this->isInArray($endBalances, $account->id);
$account->difference = bcsub($account->endBalance, $account->startBalance);
} }
); );
@ -386,7 +387,7 @@ class AccountController extends Controller
return $array[$entryId]; return $array[$entryId];
} }
return ''; return '0';
} }
/** /**

View File

@ -50,8 +50,8 @@
<em>{{ 'never'|_ }}</em> <em>{{ 'never'|_ }}</em>
</td> </td>
{% endif %} {% endif %}
<td class="hidden-sm hidden-xs" data-value="{{ account.endBalance - account.startBalance }}"> <td class="hidden-sm hidden-xs" data-value="{{ account.difference }}">
{{ (account.endBalance - account.startBalance)|formatAmount }} {{ (account.difference)|formatAmount }}
</td> </td>
</tr> </tr>