fix peratus decimal
This commit is contained in:
@@ -44,9 +44,17 @@
|
||||
{{-- @endif --}}
|
||||
@endforeach
|
||||
<tr>
|
||||
<td colspan="2"><b>Peratus Kehadiran</b></td>
|
||||
<td><b>{{ ($totalkehadiranAll / $votes) * 100 }}%</b></td>
|
||||
<td colspan="6" class="text-right"><b>Peratus Kehadiran</b></td>
|
||||
<td>
|
||||
<b>
|
||||
@php
|
||||
$percentage = $votes > 0 ? number_format(($totalkehadiranAll / $votes) * 100, 2) : '0.00';
|
||||
echo $percentage . '%';
|
||||
@endphp
|
||||
</b>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user