Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
3
3f-timesheet
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dockers
3f-timesheet
Commits
fb3e31f7
Commit
fb3e31f7
authored
Aug 16, 2022
by
hannan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
completion of verify and approval from penyokong and pelulus
parent
b2733f9f
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
442 additions
and
61 deletions
+442
-61
database/migrations/2022_08_15_174518_alter_timesheet_master.php
+34
-0
database/migrations/2022_08_16_113036_add_rejection_column_in_timesheet_master.php
+37
-0
packages/portal/timesheet/resources/views/dashboard/approvalaction.blade.php
+57
-0
packages/portal/timesheet/resources/views/dashboard/dashboardstaff.blade.php
+7
-9
packages/portal/timesheet/resources/views/dashboard/filterApproval.blade.php
+6
-0
packages/portal/timesheet/resources/views/dashboard/revaction.blade.php
+1
-1
packages/portal/timesheet/resources/views/dashboard/timesheetApproval.blade.php
+197
-0
packages/portal/timesheet/resources/views/dashboard/timesheetReview.blade.php
+79
-33
packages/portal/timesheet/resources/views/dashboard/timesheetViewer.blade.php
+12
-8
packages/portal/timesheet/resources/views/form/notelist.blade.php
+3
-8
packages/portal/timesheet/routes/web.php
+4
-0
packages/portal/timesheet/src/Http/Controllers/DashboardController.php
+0
-0
packages/portal/timesheet/src/Http/Controllers/FormController.php
+4
-1
packages/portal/timesheet/src/ServiceProvider.php
+1
-1
public/uploads/timesheet/notes/7/bookstore penang.jpeg
+0
-0
No files found.
database/migrations/2022_08_15_174518_alter_timesheet_master.php
0 → 100644
View file @
fb3e31f7
<?php
use
Illuminate\Support\Facades\Schema
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Database\Migrations\Migration
;
class
AlterTimesheetMaster
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'timesheet_master'
,
function
(
Blueprint
$table
)
{
$table
->
string
(
'hod_remarks'
,
50
)
->
after
(
'tm_timesheet_master_sts'
)
->
nullable
();
$table
->
string
(
'bod_remarks'
,
50
)
->
after
(
'hod_remarks'
)
->
nullable
();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
table
(
'timesheet_master'
,
function
(
Blueprint
$table
)
{
$table
->
dropColumn
(
'hod_remarks'
);
$table
->
dropColumn
(
'bod_remarks'
);
});
}
}
database/migrations/2022_08_16_113036_add_rejection_column_in_timesheet_master.php
0 → 100644
View file @
fb3e31f7
<?php
use
Illuminate\Support\Facades\Schema
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Database\Migrations\Migration
;
class
AddRejectionColumnInTimesheetMaster
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'timesheet_master'
,
function
(
Blueprint
$table
)
{
$table
->
date
(
'hod_rejected_at'
)
->
after
(
'tm_approved_at'
)
->
nullable
();
$table
->
date
(
'bod_dissaproved_at'
)
->
after
(
'hod_rejected_at'
)
->
nullable
();
$table
->
date
(
'hr_rejected_at'
)
->
after
(
'bod_dissaproved_at'
)
->
nullable
();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
table
(
'timesheet_master'
,
function
(
Blueprint
$table
)
{
$table
->
dropColumn
(
'hod_rejected_at'
);
$table
->
dropColumn
(
'bod_dissaproved_at'
);
$table
->
dropColumn
(
'hr_rejected_at'
);
});
}
}
packages/portal/timesheet/resources/views/dashboard/approvalaction.blade.php
0 → 100644
View file @
fb3e31f7
@
extends
(
'ui::layouts.app'
)
@
section
(
'content'
)
<
div
class
="
ui
segment
">
<a class="
ui
blue
left
ribbon
label
">Staff Timesheet Approve / Reject</a>
<br><br>
<form action="
{{
route
(
'timesheet::dashboard.approval'
)
}}
" method="
POST
" class="
ui
form
">
{
{csrf_field()}
}
<input type="
hidden
" name="
tmid
" value="
{{
data_get
(
$profile
,
'tmid'
)
}}
">
<div class="
six
wide
field
">
<label>Staff Name</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$profile
,
'fullname'
)
}}
">
</div>
<div class="
three
fields
">
<div class="
two
wide
field
">
<label>Year</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$profile
,
'tm_year'
)
}}
">
</div>
<div class="
two
wide
field
">
<label>Month</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$profile
,
'tm_month'
)
}}
">
</div>
<div class="
two
wide
field
">
<label>Phase</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$profile
,
'tm_phase'
)
}}
">
</div>
</div>
<div class="
two
fields
">
<div class="
six
wide
field
">
<input type="
hidden
" name="
approval
" value="
{{
data_get
(
$bod
,
'id'
)
}}
">
<label>Pelulus</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$bod
,
'name'
)
}}
">
</div>
<div class="
three
wide
field
">
<label>Action</label>
<select class="
ui
fluid
dropdown
" name="
action
">
<option value="
1
">Approval</option>
<option value="
2
">Reject</option>
</select>
</div>
</div>
<div class="
field
">
<label>Remarks</label>
<textarea name="
remarks
"></textarea>
</div>
<button class="
ui
green
button
" type="
submit
">Submit</button>
</form>
</div>
@endsection
\ No newline at end of file
packages/portal/timesheet/resources/views/dashboard/dashboardstaff.blade.php
View file @
fb3e31f7
...
...
@@ -59,28 +59,26 @@
<td>
@if(
$value->tm_timesheet_master_sts
== 1) Draft
@elseif(
$value->tm_timesheet_master_sts
== 2) Submitted
@elseif(
$value->tm_timesheet_master_sts
== 3) Verified by HOD
@elseif(
$value->tm_timesheet_master_sts
== 3) Verified by HOD
/HOU
@elseif(
$value->tm_timesheet_master_sts
== 4) Approved by BOD
@elseif(
$value->tm_timesheet_master_sts
== 5)
@elseif(
$value->tm_timesheet_master_sts
== 6) Rejected by PM
@elseif(
$value->tm_timesheet_master_sts
== 7) Rejected by HOD
@elseif(
$value->tm_timesheet_master_sts
== 8) Rejected by BOD
@elseif(
$value->tm_timesheet_master_sts
== 5) Dissaproved by BOD
@elseif(
$value->tm_timesheet_master_sts
== 6) Rejected by HOD/HOU
@elseif(
$value->tm_timesheet_master_sts
== 7) Rejected by BOD
@endif
</td>
<td>
@if(
$value->tm_timesheet_master_sts
== 1) Submit after timesheet completion
@elseif(
$value->tm_timesheet_master_sts
== 2) Need to verified by HOD
@elseif(
$value->tm_timesheet_master_sts
== 3) Need to approved by BOD
@elseif(
$value->tm_timesheet_master_sts
== 4)
@elseif(
$value->tm_timesheet_master_sts
== 5)
@elseif(
$value->tm_timesheet_master_sts
== 4)
Successfully received by HR
@elseif(
$value->tm_timesheet_master_sts
== 5)
Revised the timesheet
@elseif(
$value->tm_timesheet_master_sts
== 6) Revised the timesheet
@elseif(
$value->tm_timesheet_master_sts
== 7) Revised the timesheet
@elseif(
$value->tm_timesheet_master_sts
== 8) Revised the timesheet
@endif
</td>
<td>{{ data_get(
$value
,'tm_submission_at') }}</td>
<td>{{ data_get(
$value
,'tm_verified_at') }}</td>
<td>{{ data_get(
$value
,'tm_approv
al
_at') }}</td>
<td>{{ data_get(
$value
,'tm_approv
ed
_at') }}</td>
</tr>
@endforeach
</tbody>
...
...
packages/portal/timesheet/resources/views/dashboard/filterApproval.blade.php
0 → 100644
View file @
fb3e31f7
@
extends
(
'timesheet::layouts.filtermonthphase'
)
@
section
(
'action'
)
<
form
class
="
ui
form
" action="
{{
route
(
'timesheet::dashboard.approvalselectmonthphase'
)
}}
" method="
POST
">
@endsection
\ No newline at end of file
packages/portal/timesheet/resources/views/dashboard/revaction.blade.php
View file @
fb3e31f7
...
...
@@ -39,7 +39,7 @@
<div class="
three
wide
field
">
<label>Action</label>
<select class="
ui
fluid
dropdown
" name="
action
">
<option value="
1
">
Approve
</option>
<option value="
1
">
Verify
</option>
<option value="
2
">Reject</option>
</select>
</div>
...
...
packages/portal/timesheet/resources/views/dashboard/timesheetApproval.blade.php
View file @
fb3e31f7
...
...
@@ -6,6 +6,202 @@
<div class="
ui
blue
left
ribbon
label
">
Timesheet Approval
</div>
<br>
<br>
<div class="
ui
styled
fluid
accordion
">
@foreach(
$profile
as
$key
=>
$staff
)
<div class="
title
">
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th colspan="
3
" style="
width
:
60
%
;
"><i class="
dropdown
icon
"></i>{{ data_get(
$staff
,'fullname') }}</th>
<th style="
width
:
15
%
;
" class="
center
aligned
">
@if(
$staff->status
== 1 ||
$staff->status
== null) In Preparation
@elseif(
$staff->status
== 2) <i class="
red
attention
icon
"></i> Submitted
@elseif(
$staff->status
== 3) <i class="
green
check
icon
"></i> Verified by HOD/HOU
@elseif(
$staff->status
== 4) <i class="
green
check
icon
"></i>Verified by BOD
@elseif(
$staff->status
== 5) <i class="
red
attention
icon
"></i>Dissaproved by BOD
@elseif(
$staff->status
== 6) <i class="
red
attention
icon
"></i>Rejected by HOD/HOU
@elseif(
$staff->status
== 7) <i class="
red
attention
icon
"></i>Rejected by HR
@endif
</th>
<th class="
right
aligned
">
@if(
$staff->status
== 3)
<button class="
center
aligned
ui
green
icon
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
approvalaction
', [ '
tmid
'=>$staff->tmid ]) }}'
;
">Approve | Reject</button>
@else
<!-- <button class="
center
aligned
ui
green
icon
button
disabled
">Approve | Reject</button> -->
@endif
<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>
</th>
</tr>
<tr>
<td style="
width
:
20
%
;
">Chargeable (A) : {{ data_get(
$staff
,'chargeable') }}</td>
<td style="
width
:
20
%
;
">Nonchargeable (B) : {{ data_get(
$staff
,'nonchargeable') }}</td>
<td style="
width
:
20
%
;
">Overhead (C) : {{ data_get(
$staff
,'overhead') }}</td>
<td style="
width
:
15
%
;
">Overtime: {{ data_get(
$staff
,'overtime') }}</td>
<td class="
right
aligned
">Total Hours/Days: {{ data_get(
$staff
,'totalhrs')."
hours
/
".data_get(
$staff
,'totaldays')."
days
" }}</td>
</tr>
</thead>
</table>
</div>
<?php
$cptype
= "
A
";
$ncptype
= "
B
";
$otype
= "
C
";
$td
=
$checktd->where
('tm_staff_id',
$staff->staff_id
);
$detail
=
$details->where
('staffid',
$staff->staff_id
);
$ts
=
$checkts->where
('tm_staff_id',
$staff->staff_id
);
?>
<div class="
content
" style="
padding
-
top
:
0
px
;
">
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th style="
width
:
6
%
;
" class="
center
aligned
">Type</th>
<th style="
width
:
17
%
;
">Project Code</th>
<th style="
width
:
26
%
;
">Project Name</th>
<th style="
width
:
26
%
;
">Project Manager</th>
<th style="
width
:
12.5
%
;
" class="
center
aligned
">Total Hours</th>
<th style="
width
:
12.5
%
;
" class="
center
aligned
">Total Days</th>
</tr>
</thead>
@if(
$detail->where
('ptype', 1))
@foreach(
$detail->where
('ptype', 1) as
$key
=>
$chargeable
)
<tr>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$cptype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
@if(
$detail->where
('ptype', 2))
@foreach(
$detail->where
('ptype', 2) as
$key
=>
$nonchargeable
)
<tr>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$ncptype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$nonchargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$nonchargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$nonchargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
@if(
$detail->where
('ptype', 3))
@foreach(
$detail->where
('ptype', 3) as
$key
=>
$chargeable
)
<tr>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$otype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
</table>
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th style="
width
:
15
%
" class="
center
aligned
">Date</th>
<th class="
center
aligned
">Notes</th>
</tr>
</thead>
@if(
$td
)
@foreach(
$td
as
$key
=>
$value
)
@if(
$value->td_overhead_note
)
<tr>
<td style="
width
:
15
%
" class="
center
aligned
">{{ data_get(
$value
,'td_date') }}</td>
<td>{{ data_get(
$value
,'td_overhead_note') }}</td>
</tr>
@endif
@endforeach
@endif
</table>
@foreach (
$ts
as
$key
=>
$value
)
@if(data_get(
$value
,'attachement'))
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th colspan="
2
" class="
center
aligned
">Notes Attachment</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
4
%
;
"></td>
<td>
<a href="
{{
asset
(
data_get
(
$value
,
'attachement.path'
))}}
" target="
_blank
">
<button class="
ui
active
button
">
<i class="
download
icon
"></i>
Download
</button>
</a>
</td>
</tr>
</tbody>
</table>
@endif
@endforeach
@if(data_get(
$staff
,'hodremarks'))
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th class="
center
aligned
">Date</th>
<th class="
center
aligned
">Verifier</th>
<th class="
center
aligned
">Remarks by Verifier</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
15
%
;
">{{ data_get(
$staff
,'verified_at') }}</td>
<td style="
width
:
25
%
;
">{{ data_get(
$staff
,'hodname') }}</td>
<td style="
width
:
60
%
;
">{{ data_get(
$staff
,'hodremarks') }}</td>
</tr>
</tbody>
</table>
@endif
@if(data_get(
$staff
,'bodremarks'))
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th class="
center
aligned
">Date</th>
<th class="
center
aligned
">Approver</th>
<th class="
center
aligned
">Remarks by Approver</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
15
%
;
" class="
center
aligned
">{{ data_get(
$staff
,'approved_at') }}</td>
<td style="
width
:
25
%
;
" class="
center
aligned
">{{ data_get(
$staff
,'bodname') }}</td>
<td style="
width
:
60
%
;
" class="
center
aligned
">{{ data_get(
$staff
,'bodremarks') }}</td>
</tr>
</tbody>
</table>
@endif
</div>
@endforeach
</div>
</div>
@endsection
@push('script')
<script>
$('.ui.accordion').accordion();
</script>
@endpush
\ No newline at end of file
packages/portal/timesheet/resources/views/dashboard/timesheetReview.blade.php
View file @
fb3e31f7
...
...
@@ -21,17 +21,20 @@
<th style="
width
:
15
%
;
" class="
center
aligned
">
@if(
$staff->status
== 1 ||
$staff->status
== null) In Preparation
@elseif(
$staff->status
== 2) <i class="
red
attention
icon
"></i> Submitted
@elseif(
$staff->status
== 3) <i class="
green
check
icon
"></i> Verified by HOD
@elseif(
$staff->status
== 4) Verified by BOD
@elseif(
$staff->status
== 3) <i class="
green
check
icon
"></i> Verified by HOD/HOU
@elseif(
$staff->status
== 4) <i class="
green
check
icon
"></i>Verified by BOD
@elseif(
$staff->status
== 5) <i class="
red
attention
icon
"></i>Dissaproved by BOD
@elseif(
$staff->status
== 6) <i class="
red
attention
icon
"></i>Rejected by HOD/HOU
@elseif(
$staff->status
== 7) <i class="
red
attention
icon
"></i>Rejected by HR
@endif
</th>
<th class="
right
aligned
">
@if(
$staff->status
< 3)
<button class="
center
aligned
ui
green
icon
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
revaction
', [ '
tmid
'=>$staff->tmid ]) }}'
;
">
Approve
| Reject</button>
<button class="
center
aligned
ui
green
icon
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
revaction
', [ '
tmid
'=>$staff->tmid ]) }}'
;
">
Verify
| Reject</button>
@else
<
button class="
center
aligned
ui
green
icon
button
disabled
">Approve | Reject</button>
<
!-- <button class="
center
aligned
ui
green
icon
button
disabled
">Approve | Reject</button> -->
@endif
<button class="
center
aligned
ui
blue
icon
button
">View</button>
<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>
</th>
</tr>
<tr>
...
...
@@ -51,57 +54,55 @@
$otype
= "
C
";
$td
=
$checktd->where
('tm_staff_id',
$staff->staff_id
);
$detail
=
$details->where
('staffid',
$staff->staff_id
);
$ts
=
$checkts->where
('tm_staff_id',
$staff->staff_id
);
// dump(
$ts
);
?>
<div class="
content
" style="
padding
-
top
:
0
px
;
">
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th style="
width
:
5
%
;
" class="
center
aligned
">Type</th>
<th style="
width
:
15
%
;
">Project Code</th>
<th style="
width
:
20
%
;
">Project Name</th>
<th style="
width
:
20
%
;
">Project Manager</th>
<th style="
width
:
7.5
%
;
" class="
center
aligned
">Total Hours</th>
<th style="
width
:
7.5
%
;
" class="
center
aligned
">Total Days</th>
<th style="
width
:
25
%
;
" class="
center
aligned
">Remarks</th>
<th style="
width
:
6
%
;
" class="
center
aligned
">Type</th>
<th style="
width
:
17
%
;
">Project Code</th>
<th style="
width
:
26
%
;
">Project Name</th>
<th style="
width
:
26
%
;
">Project Manager</th>
<th style="
width
:
12.5
%
;
" class="
center
aligned
">Total Hours</th>
<th style="
width
:
12.5
%
;
" class="
center
aligned
">Total Days</th>
</tr>
</thead>
@if(
$detail->where
('ptype', 1))
@foreach(
$detail->where
('ptype', 1) as
$key
=>
$chargeable
)
<tr>
<td style="
width
:
5
%
;
" class="
center
aligned
">{{
$cptype
}}</td>
<td style="
width
:
15
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
<td style="
width
:
25
%
;
" class="
center
aligned
"></td>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$cptype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
@if(
$detail->where
('ptype', 2))
@foreach(
$detail->where
('ptype', 2) as
$key
=>
$nonchargeable
)
<tr>
<td style="
width
:
5
%
;
" class="
center
aligned
">{{
$ncptype
}}</td>
<td style="
width
:
15
%
;
">{{ data_get(
$nonchargeable
, 'pcode') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$nonchargeable
, 'pname') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$nonchargeable
, 'pmname') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours')/8 }}</td>
<td style="
width
:
25
%
;
" class="
center
aligned
"></td>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$ncptype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$nonchargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$nonchargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$nonchargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$nonchargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
@if(
$detail->where
('ptype', 3))
@foreach(
$detail->where
('ptype', 3) as
$key
=>
$chargeable
)
<tr>
<td style="
width
:
5
%
;
" class="
center
aligned
">{{
$otype
}}</td>
<td style="
width
:
15
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
20
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
7.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
<td style="
width
:
25
%
;
" class="
center
aligned
"></td>
<td style="
width
:
6
%
;
" class="
center
aligned
">{{
$otype
}}</td>
<td style="
width
:
17
%
;
">{{ data_get(
$chargeable
, 'pcode') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pname') }}</td>
<td style="
width
:
26
%
;
">{{ data_get(
$chargeable
, 'pmname') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours') }}</td>
<td style="
width
:
12.5
%
;
" class="
center
aligned
">{{ data_get(
$chargeable
, 'hours')/8 }}</td>
</tr>
@endforeach
@endif
...
...
@@ -125,6 +126,51 @@
@endforeach
@endif
</table>
@foreach (
$ts
as
$key
=>
$value
)
@if(data_get(
$value
,'attachement'))
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th colspan="
2
" class="
center
aligned
">Notes Attachment</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
4
%
;
"></td>
<td>
<a href="
{{
asset
(
data_get
(
$value
,
'attachement.path'
))}}
" target="
_blank
">
<button class="
ui
active
button
">
<i class="
download
icon
"></i>
Download
</button>
</a>
</td>
</tr>
</tbody>
</table>
@endif
@endforeach
@if(data_get(
$staff
,'hodremarks'))
<table class="
ui
unstackable
celled
table
">
<thead>
<tr>
<th colspan="
2
" class="
center
aligned
">Remarks</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
4
%
;
"></td>
<td>{{ data_get(
$staff
,'hodremarks') }}</td>
</tr>
</tbody>
</table>
@endif
</div>
@endforeach
</div>
...
...
packages/portal/timesheet/resources/views/dashboard/timesheetViewer.blade.php
View file @
fb3e31f7
...
...
@@ -527,12 +527,12 @@
<table id="
printtable5
" class="
ui
celled
structured
table
unstackable
">
<thead>
<tr>
<th colspan="
2
" class="
center
aligned
">
Notes
Attachment</th>
<th colspan="
2
" class="
center
aligned
">Attachment</th>
</tr>
</thead>
<tbody>
<tr>
<td style="
width
:
13.5
%
;
">Notes Attachement
</td>
<td style="
width
:
4
%
;
">
</td>
<td>
<a href="
{{
asset
(
data_get
(
$check
,
'attachement.path'
))}}
" target="
_blank
">
...
...
@@ -551,11 +551,6 @@
<div class="
ui
segment
">
<table id="
printtabl6
" class="
ui
celled
structured
table
unstackable
">
<!-- <thead>
<th colspan="
@
if
(
$phase
==
1
)
17
@
else
{{
$daymonth
-
13
}}
@
endif
"></th>
<th>Total hours</th>
<th>Total days</th>
</thead> -->
<tbody>
<tr>
<td style="
width
:
4
%
;
"></td>
...
...
@@ -765,12 +760,21 @@
<br>
<button type="
button
" class="
ui
primary
button
" onclick="
printdiv
(
'print_div'
)
">Print</button>
@if(
$curruser->id
==
$user->penyokong
)
<button type="
button
" class="
ui
green
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
timesheetReview
',[ '
phase
' => $phase, '
month
' => $month ]) }}'
;
">Back</button>
@elseif(
$curruser->id
==
$user->pelulus
)
<button type="
button
" class="
ui
green
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
timesheetApproval
',[ '
phase
' => $phase, '
month
' => $month ]) }}'
;
">Back</button>
@else
@if(
$check
!= null)
<button type="
button
" class="
ui
green
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
tsubmit
',[ '
tid
'=> $check->id, '
totalot
'=> $totalot, '
totalchargehrs
'=>$totalchargehrs, '
totalnonchargehrs
'=> $totalnonchargehrs, '
totaloverheadhrs
'=>$totaloverheadhrs ]) }}'
;
">Submit</button>
@else
<button type="
button
" class="
ui
disabled
green
button
">Submit</button>
@endif
@endif
<button type="
button
" class="
ui
primary
button
" onclick="
printdiv
(
'print_div'
)
">Print</button>
</div>
...
...
packages/portal/timesheet/resources/views/form/notelist.blade.php
View file @
fb3e31f7
...
...
@@ -16,7 +16,6 @@
<div class="
field
">
<label>Title</label>
<input type="
file
" name="
attachment
" id="
uploadfile
" style="">
</div>
<button class="
ui
blue
button
" type="
submit
">Upload</button>
</form>
...
...
@@ -25,17 +24,13 @@
<div class="
ui
unstackable
segment
">
<a class="
ui
blue
left
ribbon
label
">Senarai Notes</a>
kalau user dept bdd, display upload files.
<!-- <form action="">
<label for="
uploadfile
" class="
ui
right
floated
small
purple
labeled
icon
button
">
<i class="
plus
icon
"></i>Upload Attachment
</label>
<input type="
file
" name="
attachment
" id="
uploadfile
" style="
display
:
none
;
">
</form> -->
@if(data_get(
$staff
,'fk_lkp_department') == 7)
<button class="
ui
right
floated
small
purple
labeled
icon
button
" id="
uploadmodal
">
<i class="
file
icon
"></i>
Upload File
</button>
@endif
<a href="
{{
route
(
'timesheet::form.penambahannote'
)
}}
" class="
ui
right
floated
small
yellow
labeled
icon
button
">
<i class="
plus
icon
"></i>Add New Notes
...
...
packages/portal/timesheet/routes/web.php
View file @
fb3e31f7
...
...
@@ -20,11 +20,15 @@ Route::group(
Route
::
get
(
'timesheetViewer'
,[
'uses'
=>
'DashboardController@timesheetViewer'
,
'as'
=>
'dashboard.timesheetViewer'
]);
Route
::
get
(
'filterReview'
,[
'uses'
=>
'DashboardController@filterReview'
,
'as'
=>
'dashboard.filterReview'
]);
Route
::
get
(
'filterViewer'
,[
'uses'
=>
'DashboardController@filterViewer'
,
'as'
=>
'dashboard.filterViewer'
]);
Route
::
get
(
'filterApproval'
,[
'uses'
=>
'DashboardController@filterApproval'
,
'as'
=>
'dashboard.filterApproval'
]);
Route
::
post
(
'reviewselectmonthphase'
,
[
'uses'
=>
'DashboardController@reviewselectmonthphase'
,
'as'
=>
'dashboard.reviewselectmonthphase'
]);
Route
::
post
(
'viewerselectmonthphase'
,
[
'uses'
=>
'DashboardController@viewerselectmonthphase'
,
'as'
=>
'dashboard.viewerselectmonthphase'
]);
Route
::
post
(
'approvalselectmonthphase'
,
[
'uses'
=>
'DashboardController@approvalselectmonthphase'
,
'as'
=>
'dashboard.approvalselectmonthphase'
]);
Route
::
get
(
'tsubmit'
,
[
'uses'
=>
'DashboardController@tsubmit'
,
'as'
=>
'dashboard.tsubmit'
]);
Route
::
get
(
'revaction'
,
[
'uses'
=>
'DashboardController@revaction'
,
'as'
=>
'dashboard.revaction'
]);
Route
::
get
(
'approvalaction'
,
[
'uses'
=>
'DashboardController@approvalaction'
,
'as'
=>
'dashboard.approvalaction'
]);
Route
::
post
(
'verify'
,
[
'uses'
=>
'DashboardController@verify'
,
'as'
=>
'dashboard.verify'
]);
Route
::
post
(
'approval'
,
[
'uses'
=>
'DashboardController@approval'
,
'as'
=>
'dashboard.approval'
]);
//maintenance
Route
::
get
(
'senaraiProject'
,[
'uses'
=>
'MaintenanceController@senaraiProject'
,
'as'
=>
'maintenance.senaraiProject'
]);
...
...
packages/portal/timesheet/src/Http/Controllers/DashboardController.php
View file @
fb3e31f7
This diff is collapsed.
Click to expand it.
packages/portal/timesheet/src/Http/Controllers/FormController.php
View file @
fb3e31f7
...
...
@@ -978,6 +978,9 @@ class FormController extends Controller
$userId
=
Users
::
find
(
Auth
::
id
())
->
u_staffID
;
$staff
=
Staff_info
::
find
(
Auth
::
id
());
// dd($staff->fk_lkp_department);
$year
=
date
(
'Y'
);
if
(
isset
(
$request
->
phase
))
...
...
@@ -1017,7 +1020,7 @@ class FormController extends Controller
$fk_tm_id
=
null
;
}
return
view
(
'timesheet::form.notelist'
,
compact
(
'notes'
,
'phase'
,
'month'
,
'year'
,
'fk_tm_id'
));
return
view
(
'timesheet::form.notelist'
,
compact
(
'notes'
,
'phase'
,
'month'
,
'year'
,
'fk_tm_id'
,
'staff'
));
}
public
function
penambahannote
()
...
...
packages/portal/timesheet/src/ServiceProvider.php
View file @
fb3e31f7
...
...
@@ -93,7 +93,7 @@ class ServiceProvider extends BaseServiceProvider
->
data
(
'icon'
,
'file alternate icon'
)
->
active
(
'timesheetReview/*'
)
->
data
(
'permission'
,
Permission
::
kehadiran
);
$form
->
add
(
__
(
'Timesheet Approval'
))
$form
->
add
(
__
(
'Timesheet Approval'
)
,
route
(
'timesheet::dashboard.filterApproval'
)
)
->
data
(
'icon'
,
'check square icon'
)
->
active
(
'timesheetApproval/*'
)
->
data
(
'permission'
,
Permission
::
kehadiran
);
...
...
public/uploads/timesheet/notes/7/bookstore penang.jpeg
0 → 100644
View file @
fb3e31f7
155 KB
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment