Skip to content

Commit

Permalink
close #583 Fixed: Reports page currency issue
Browse files Browse the repository at this point in the history
  • Loading branch information
cuneytsenturk committed Nov 2, 2018
1 parent dd836a9 commit 5da2276
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion resources/views/reports/expense_summary/body.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<tr>
<td>{{ $categories[$category_id] }}</td>
@foreach($category as $item)
<td class="text-right">@money($item['amount'], $item['currency_code'], true)</td>
<td class="text-right">@money($item['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
@endforeach
Expand Down
4 changes: 2 additions & 2 deletions resources/views/reports/income_expense_summary/body.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
@endif
@foreach($category as $item)
@if($type == 'income')
<td class="text-right">@money($item['amount'], $item['currency_code'], true)</td>
<td class="text-right">@money($item['amount'], setting('general.default_currency'), true)</td>
@else
<td class="text-right">@money(-$item['amount'], $item['currency_code'], true)</td>
<td class="text-right">@money(-$item['amount'], setting('general.default_currency'), true)</td>
@endif
@endforeach
</tr>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/reports/income_summary/body.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<tr>
<td>{{ $categories[$category_id] }}</td>
@foreach($category as $item)
<td class="text-right">@money($item['amount'], $item['currency_code'], true)</td>
<td class="text-right">@money($item['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
@endforeach
Expand Down
4 changes: 2 additions & 2 deletions resources/views/reports/profit_loss/body.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<td class="col-sm-2">{{ $income_categories[$category_id] }}</td>
@foreach($category as $i => $item)
@php $gross['income'][$i] += $item['amount']; @endphp
<td class="col-sm-2 text-right">@money($item['amount'], $item['currency_code'], true)</td>
<td class="col-sm-2 text-right">@money($item['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
@endforeach
Expand All @@ -49,7 +49,7 @@
<td class="col-sm-2">{{ $expense_categories[$category_id] }}</td>
@foreach($category as $i => $item)
@php $gross['expense'][$i] += $item['amount']; @endphp
<td class="col-sm-2 text-right">@money($item['amount'], $item['currency_code'], true)</td>
<td class="col-sm-2 text-right">@money($item['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
@endforeach
Expand Down
6 changes: 3 additions & 3 deletions resources/views/reports/tax_summary/body.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,21 @@
<tr>
<td style="width: 120px;">{{ trans_choice('general.incomes', 2) }}</td>
@foreach($incomes[$tax_name] as $tax_date)
<td class="text-right">@money($tax_date['amount'], $tax_date['currency_code'], true)</td>
<td class="text-right">@money($tax_date['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
<tr>
<td style="width: 120px;">{{ trans_choice('general.expenses', 2) }}</td>
@foreach($expenses[$tax_name] as $tax_date)
<td class="text-right">@money($tax_date['amount'], $tax_date['currency_code'], true)</td>
<td class="text-right">@money($tax_date['amount'], setting('general.default_currency'), true)</td>
@endforeach
</tr>
</tbody>
<tfoot>
<tr>
<th style="width: 120px;">{{ trans('reports.net') }}</th>
@foreach($totals[$tax_name] as $tax_date)
<th class="text-right">@money($tax_date['amount'], $tax_date['currency_code'], true)</th>
<th class="text-right">@money($tax_date['amount'], setting('general.default_currency'), true)</th>
@endforeach
</tr>
</tfoot>
Expand Down

0 comments on commit 5da2276

Please sign in to comment.