Browse Source

Change monthId() to month_id()

pull/32/head
Nafies Luthfi 7 years ago
parent
commit
2f436da1f4
  1. 2
      app/helpers.php
  2. 8
      resources/views/reports/payments/yearly.blade.php

2
app/helpers.php

@ -105,7 +105,7 @@ function monthNumber($number)
* @param int|string $monthNumber
* @return string
*/
function monthId($monthNumber)
function month_id($monthNumber)
{
if (is_null($monthNumber)) {
return $monthNumber;

8
resources/views/reports/payments/yearly.blade.php

@ -42,7 +42,7 @@
$any = isset($reports[$monthNumber]);
@endphp
<tr>
<td class="text-center">{{ monthId($monthNumber) }}</td>
<td class="text-center">{{ month_id($monthNumber) }}</td>
<td class="text-center">{{ $any ? $reports[$monthNumber]->count : 0 }}</td>
<td class="text-right">{{ formatRp($any ? $reports[$monthNumber]->cashin : 0) }}</td>
<td class="text-right">{{ formatRp($any ? $reports[$monthNumber]->cashout : 0) }}</td>
@ -54,14 +54,14 @@
['month' => $monthNumber, 'year' => $year],
[
'class' => 'btn btn-info btn-xs',
'title' => __('report.monthly', ['year_month' => monthId($monthNumber)]),
'title' => __('report.monthly', ['year_month' => monthId($monthNumber).' '.$year]),
'title' => __('report.monthly', ['year_month' => month_id($monthNumber)]),
'title' => __('report.monthly', ['year_month' => month_id($monthNumber).' '.$year]),
]
) }}
</td>
</tr>
@php
$chartData[] = ['month' => monthId($monthNumber), 'value' => $profit];
$chartData[] = ['month' => month_id($monthNumber), 'value' => $profit];
@endphp
@endforeach
</tbody>

Loading…
Cancel
Save