Commit e2afcfa5 by Azhan Hannan

timesheet viewer -> filter null data & filter column penyokong

parent a9c41025
...@@ -89,6 +89,7 @@ ...@@ -89,6 +89,7 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@if(count($chargeablelist) > 0)
@foreach($chargeablelist as $key => $projectchargeable) @foreach($chargeablelist as $key => $projectchargeable)
<?php $totalcharge = 0; ?> <?php $totalcharge = 0; ?>
<tr> <tr>
...@@ -163,10 +164,13 @@ ...@@ -163,10 +164,13 @@
<td style="width: 5%">0</td> <td style="width: 5%">0</td>
<td style="width: 5%">0</td> <td style="width: 5%">0</td>
@endif @endif
</tr> </tr>
@endforeach @endforeach
@else
<tr>
<td class="text-center" colspan="@if($phase==1){{5+15}} @else {{5+($daymonth-15)}} @endif">No Data Overhead</td>
</tr>
@endif
</tbody> </tbody>
<tfoot> <tfoot>
<th colspan="3">Total (A)</th> <th colspan="3">Total (A)</th>
...@@ -248,10 +252,10 @@ ...@@ -248,10 +252,10 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@if(count($overheadlist) > 0)
@foreach($overheadlist as $key => $projectoverhead) @foreach($overheadlist as $key => $projectoverhead)
<?php <?php
$totaloverhead = 0; $totaloverhead = 0;
// dd($overheadlist);
?> ?>
<tr> <tr>
<td style="width: 4%;"></td> <td style="width: 4%;"></td>
...@@ -316,9 +320,13 @@ ...@@ -316,9 +320,13 @@
<td style="width: 5%">0</td> <td style="width: 5%">0</td>
<td style="width: 5%">0</td> <td style="width: 5%">0</td>
@endif @endif
</tr> </tr>
@endforeach @endforeach
@else
<tr>
<td class="text-center" colspan="@if($phase==1){{4+15}} @else {{4+($daymonth-15)}} @endif">No Data Overhead</td>
</tr>
@endif
</tbody> </tbody>
<tfoot> <tfoot>
<th colspan="2">Total (B)</th> <th colspan="2">Total (B)</th>
...@@ -382,11 +390,18 @@ ...@@ -382,11 +390,18 @@
<td>{{ data_get($value,'td_overhead_note') }}</td> <td>{{ data_get($value,'td_overhead_note') }}</td>
</tr> </tr>
@endforeach @endforeach
@else
<tr>
<td colspan="3" class="text-center">No Data Overhead</td>
</tr>
@endif @endif
</tbody> </tbody>
</table> </table>
</div>
@if(data_get($check,'attachement')) @if(data_get($check,'attachement'))
<table id="printtable5" class="ui celled structured table unstackable"> <div class="ui segment">
<table id="printtable8" class="ui celled structured table unstackable">
<thead> <thead>
<tr> <tr>
<th class="center aligned">Title</th> <th class="center aligned">Title</th>
...@@ -408,15 +423,14 @@ ...@@ -408,15 +423,14 @@
</tr> </tr>
</tbody> </tbody>
</table> </table>
@endif
</div> </div>
@endif
<div class="ui segment"> <div class="ui segment">
<table id="printtabl6" class="ui celled structured table unstackable"> <table id="printtable6" class="ui celled structured table unstackable">
<tbody> <tbody>
<tr> <tr>
<td style="width: 4%;"></td> <td style="width: 4%"></td>
<td style="width: 23%;">Total (A) + (B) Working Hours</td> <td style="width: 23%;">Total (A) + (B) Working Hours</td>
@if( $phase == 1 ) @if( $phase == 1 )
@for($i = 0; $i < 15 ; $i++) @for($i = 0; $i < 15 ; $i++)
...@@ -481,12 +495,12 @@ ...@@ -481,12 +495,12 @@
<td style="width: 4%;">{{ number_format($ac, '1', '.', '') }}</td> <td style="width: 4%;">{{ number_format($ac, '1', '.', '') }}</td>
@endfor @endfor
@endif @endif
<td> @if($check) {{ number_format(($totalchargehrs + $totaloverheadhrs), 1, '.', '') }} @else 0 @endif </td> <td style="width: 5%;"> @if($check) {{ number_format(($totalchargehrs + $totaloverheadhrs), 1, '.', '') }} @else 0 @endif </td>
<td> {{ number_format(($totalchargehrs + $totaloverheadhrs)/8, 1, '.', '') }} </td> <td style="width: 5%;"> {{ number_format(($totalchargehrs + $totaloverheadhrs)/8, 1, '.', '') }} </td>
</tr> </tr>
<tr> <tr>
<td style="width: 4%;"></td> <td style="width: 4%"></td>
<td style="width: 23%;">Total (A+B) - 8 Overtime</td> <td style="width: 23%;">Total (A+B) - 8 Overtime</td>
<?php $totalot = 0; ?> <?php $totalot = 0; ?>
@if( $phase == 1 ) @if( $phase == 1 )
...@@ -583,6 +597,7 @@ ...@@ -583,6 +597,7 @@
</table> </table>
</div> </div>
@if(data_get($profile,'HOD_NAME'))
<div class="ui segment"> <div class="ui segment">
<table id="printtable7" class="ui celled structured table unstackable"> <table id="printtable7" class="ui celled structured table unstackable">
<thead> <thead>
...@@ -606,6 +621,28 @@ ...@@ -606,6 +621,28 @@
</tbody> </tbody>
</table> </table>
</div> </div>
@else
<div class="ui segment">
<table id="printtable7" class="ui celled structured table unstackable">
<thead>
<tr>
<th style="width: 50%;" class="center aligned">Staff Signature</th>
<th style="width: 50%;" class="center aligned">Approved by</th>
</tr>
</thead>
<tbody>
<tr>
<td style="width: 50%;" class="center aligned"><br><br></td>
<td style="width: 50%;" class="center aligned"><br><br></td>
</tr>
<tr>
<td style="width: 50%;" class="center aligned">@if($profile){{ data_get($profile,'STAFF_NAME') }}@endif</td>
<td style="width: 50%;" class="center aligned">@if($profile){{ data_get($profile,'BOD_NAME') }}@endif</td>
</tr>
</tbody>
</table>
</div>
@endif
</div> </div>
<br> <br>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment