Commit 8d742d8e by Azhan Hannan

changes timesheet review

parent dc9e756b
......@@ -12,9 +12,10 @@
@foreach($profile as $key => $staff)
@if(data_get($staff,'status') == 2)
<?php
$detail = $details->where('staffid', $staff->staff_id)->where('fk_tm_id', $staff->tmid)->where('tp_project_sts', 2);
// $detail = $details->where('staffid', $staff->staff_id)->where('fk_tm_id', $staff->tmid)->where('tp_project_sts', 2);
$detail = $details->where('staffid', $staff->staff_id)->where('fk_tm_id', $staff->tmid);
// dump(count($detail));
$ts = $checkts->where('tm_staff_id', $staff->staff_id);
// dump($detail);
?>
@if(count($detail) > 0)
......
......@@ -14,7 +14,10 @@
<table class="ui unstackable celled table">
<thead>
<tr>
<th style="width: 60%;"><i class="dropdown icon"></i>{{ data_get($staff,'fullname') }}</th>
<th style="width: 40%;"><i class="dropdown icon"></i>{{ data_get($staff,'fullname') }}</th>
<th style="width: 20%" class="text-center">
@if(data_get($staff,'tm_phase') == 1) 1st Halfmonth @else 2nd Half-month @endif - {{ date("F", mktime(0, 0, 0, data_get($staff,'tm_month'), 10)) }} - {{ data_get($staff,'tm_year') }}
</th>
<th style="width: 15%;" class="center aligned">
<?php
$over = 0;
......@@ -35,9 +38,9 @@
@elseif($staff->status == 1 || $staff->status == null) In Preparation
@endif
</th>
<th style="width: 13%" class="text-center">Submitted on: {{data_get($staff,'submission')}}</th>
<th style="width: 13%" class="text-center">Submitted on: {{ date("d/m/Y", strtotime(data_get($staff,'submission'))) }}</th>
<th style="width: 12%" class="text-center">
<button class="center aligned ui blue icon button" onclick="window.location.href='{{ route('timesheet::dashboard.timesheetViewer', [ 'user'=>data_get($staff,'staff_id') ,'phase' => $phase, 'month' => $month, 'year' => $year ]) }}';" target='_blank'>View</button>
<button class="center aligned ui blue icon button">View Details</button>
</th>
</tr>
</thead>
......@@ -79,12 +82,13 @@
@elseif(data_get($tp, 'tp_timesheet_sts') == 7) <i class="red attention icon"></i>Rejected by HR
@endif
</td>
<td style="width: 12%;" class="text-center">
<td style="width: 12%;" class="text-center single line">
@if(data_get($tp, 'tp_timesheet_sts') == 2)
<button class="center aligned ui green icon button" onclick="window.location.href='{{route('timesheet::dashboard.revaction', ['tpid'=>data_get($tp, 'id'), 'phase'=>$phase, 'month'=>$month, 'year'=>$year ]) }}';">Verify | Reject</button>
@else
<button class="center aligned ui green icon button disabled">Verify | Reject</button>
@endif
<a href="{{ route('timesheet::dashboard.timesheetViewer', [ 'user'=>data_get($staff,'staff_id') ,'phase' => $phase, 'month' => $month, 'year' => $year ]) }}" class="center aligned ui blue icon button" target='_blank'>View</a>
</td>
</tr>
@endif
......
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