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
1b125b1e
Commit
1b125b1e
authored
Jun 29, 2022
by
hannan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
filter pm selection, changes in overhead description modal, validation and check null error
parent
8f784e21
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
163 additions
and
77 deletions
+163
-77
packages/portal/timesheet/resources/views/ajax/senaraistaff.blade.php
+9
-6
packages/portal/timesheet/resources/views/dashboard/chargeableForm.blade.php
+1
-1
packages/portal/timesheet/resources/views/dashboard/editProjectTeam.blade.php
+1
-1
packages/portal/timesheet/resources/views/dashboard/nonChargeableForm.blade.php
+3
-3
packages/portal/timesheet/resources/views/dashboard/overheadForm.blade.php
+6
-7
packages/portal/timesheet/resources/views/dashboard/penambahanProject.blade.php
+6
-4
packages/portal/timesheet/resources/views/dashboard/penambahanProjectTeam.blade.php
+1
-1
packages/portal/timesheet/resources/views/dashboard/senaraiProject.blade.php
+4
-4
packages/portal/timesheet/routes/web.php
+4
-2
packages/portal/timesheet/src/Http/Controllers/DashboardController.php
+118
-48
packages/portal/timesheet/src/Model/Project.php
+5
-0
packages/portal/timesheet/src/Model/Staff_info.php
+5
-0
No files found.
packages/portal/timesheet/resources/views/ajax/senaraistaff.blade.php
View file @
1b125b1e
@
foreach
(
$staffs
as
$key
=>
$staff
)
@
if
(
$staffs
)
<
div
class
="
item
" data-value="
{{
$staff
->
id
}}
" data-text="
{{
$staff
->
fullname
}}
">
@
foreach
(
$staffs
as
$key
=>
$staff
)
{
{$staff->fullname}
}
<
div
class
="
item
" data-value="
{{
$staff
->
id
}}
" data-text="
{{
$staff
->
fullname
}}
">
</div>
{
{$staff->fullname}
}
@endforeach
</div>
\ No newline at end of file
@endforeach
@else
@endif
\ No newline at end of file
packages/portal/timesheet/resources/views/dashboard/chargeableForm.blade.php
View file @
1b125b1e
...
@@ -45,7 +45,7 @@ input[type=number] {
...
@@ -45,7 +45,7 @@ input[type=number] {
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<table class="
ui
celled
structured
table
">
<table class="
ui
celled
structured
table
unstackable
">
<thead>
<thead>
<tr>
<tr>
<th colspan="
2
">Chargeable</th>
<th colspan="
2
">Chargeable</th>
...
...
packages/portal/timesheet/resources/views/dashboard/editProjectTeam.blade.php
View file @
1b125b1e
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
<div class="
field
">
<div class="
field
">
<label>Role</label>
<label>Role</label>
<select name="
role
" class="
ui
fluid
dropdown
">
<select name="
role
" class="
ui
fluid
dropdown
">
<option value="
">Role
</option>
<option value="
{{
$team
->
role_id
}}
">
{
{$teamRole->role}
}
</option>
@foreach(
$role
as
$key
=>
$value
)
@foreach(
$role
as
$key
=>
$value
)
<option value="
{{
$value
->
id
}}
">
{
{$value->role}
}
</option>
<option value="
{{
$value
->
id
}}
">
{
{$value->role}
}
</option>
@endforeach
@endforeach
...
...
packages/portal/timesheet/resources/views/dashboard/nonChargeableForm.blade.php
View file @
1b125b1e
...
@@ -29,9 +29,9 @@ input[type=number] {
...
@@ -29,9 +29,9 @@ input[type=number] {
<input type="
hidden
" name="
chargeableProject
">
<input type="
hidden
" name="
chargeableProject
">
<i class="
dropdown
icon
"></i>
<i class="
dropdown
icon
"></i>
<div class="
default
text
">Task</div>
<div class="
default
text
">Task</div>
<div class="
menu
">
<div class="
menu
">
@foreach(
$nonchargeables
as
$key
=>
$nonchargeable
)
@foreach(
$nonchargeables
as
$key
=>
$nonchargeable
)
<div class="
item
" data-value="
{{
$nonchargeable
->
id
}}
">
{
{
$nonchargeable->p_project_description
}
}
</div>
<div class="
item
" data-value="
{{
$nonchargeable
->
id
}}
">{{
data_get(
$nonchargeable
, 'p_project_description')
}}</div>
@endforeach
@endforeach
</div>
</div>
</div>
</div>
...
@@ -98,7 +98,7 @@ input[type=number] {
...
@@ -98,7 +98,7 @@ input[type=number] {
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<table class="
ui
celled
structured
table
">
<table class="
ui
celled
structured
table
unstackable
">
<thead>
<thead>
<tr>
<tr>
<th class="
single
line
">Non-Chargeable</th>
<th class="
single
line
">Non-Chargeable</th>
...
...
packages/portal/timesheet/resources/views/dashboard/overheadForm.blade.php
View file @
1b125b1e
...
@@ -45,7 +45,8 @@ input[type=number] {
...
@@ -45,7 +45,8 @@ input[type=number] {
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
year
" value="
{{
$year
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
month
" value="
{{
$month
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<input type="
hidden
" name="
phase
" value="
{{
$phase
}}
">
<table class="
ui
celled
structured
table
">
<table class="
ui
celled
structured
unstackable
table
" >
<thead>
<thead>
<tr>
<tr>
<th>Overhead</th>
<th>Overhead</th>
...
@@ -101,7 +102,7 @@ input[type=number] {
...
@@ -101,7 +102,7 @@ input[type=number] {
}
}
?>
?>
<td >
<td >
<input type="
text
" onkeypress="
onlynumber
(
event
)
" id="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" name="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" value="
@
if
(
$valuehour
){{
$valuehour
->
td_hours
}}
@
else
@
endif
" min="
0
" max="
24
" style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
<input type="
text
" onkeypress="
onlynumber
(
event
)
" id="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" name="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" value="
@
if
(
$valuehour
){{
$valuehour
->
td_hours
}}
@
else
@
endif
" min="
0
" max="
24
"
size="
2
"
style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
</td>
</td>
@endfor
@endfor
@else
@else
...
@@ -122,7 +123,6 @@ input[type=number] {
...
@@ -122,7 +123,6 @@ input[type=number] {
$total
+= data_get(
$valuehour
,'td_hours');
$total
+= data_get(
$valuehour
,'td_hours');
}
}
?>
?>
<td >
<td >
<input type="
text
" onkeypress="
onlynumber
(
event
)
" id="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" name="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" value="
@
if
(
$valuehour
){{
$valuehour
->
td_hours
}}
@
else
@
endif
" min="
0
" max="
24
" style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
<input type="
text
" onkeypress="
onlynumber
(
event
)
" id="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" name="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" value="
@
if
(
$valuehour
){{
$valuehour
->
td_hours
}}
@
else
@
endif
" min="
0
" max="
24
" style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
...
@@ -130,9 +130,7 @@ input[type=number] {
...
@@ -130,9 +130,7 @@ input[type=number] {
@endfor
@endfor
@endif
@endif
<td>
<td>
<button class="
ui
center
blue
button
">
<input type="
text
" name="
desc
" value="
icon
">
<i class="
ui
center
edit
white
icon
"></i>
</button>
</td>
</td>
<td>
<td>
<input type="
text
" onkeypress="
onlynumber
(
event
)
" name="
total
-
{{
$project
[
'td_project'
]}}
" id="
total
-
{{
$project
[
'td_project'
]}}
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
" readonly="" value=
{
{$total}
}
>
<input type="
text
" onkeypress="
onlynumber
(
event
)
" name="
total
-
{{
$project
[
'td_project'
]}}
" id="
total
-
{{
$project
[
'td_project'
]}}
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
" readonly="" value=
{
{$total}
}
>
...
@@ -153,7 +151,8 @@ input[type=number] {
...
@@ -153,7 +151,8 @@ input[type=number] {
<i class="
angle
double
left
icon
"></i>
<i class="
angle
double
left
icon
"></i>
Phase 1
Phase 1
</button>
</button>
@endif
@endif
</div>
</div>
@endsection
@endsection
...
...
packages/portal/timesheet/resources/views/dashboard/penambahanProject.blade.php
View file @
1b125b1e
...
@@ -18,19 +18,21 @@
...
@@ -18,19 +18,21 @@
<label>Project Manager</label>
<label>Project Manager</label>
<select name="
projectmanager
" class="
ui
fluid
dropdown
">
<select name="
projectmanager
" class="
ui
fluid
dropdown
">
<option value="">Project Manager</option>
<option value="">Project Manager</option>
<option value="
842
">Rashdan</option>
@foreach(
$pm
as
$key
=>
$value
)
<option value="
920
">Maimunah</option>
<option value="
{{
$value
->
staff_id
}}
">
{
{$value->fullname}
}
</option>
@endforeach
</select>
</select>
</div>
</div>
<div class="
field
">
<div class="
field
">
<label>Project Status</label>
<label>Project Status</label>
<select name="
status
" class="
ui
fluid
dropdown
">
<select name="
status
" class="
ui
fluid
dropdown
">
<
option value="">Project Status</option
>
<
!-- <option value="">Project Status</option> --
>
<option value="
1
">Active</option>
<option value="
1
">Active</option>
<option value="
0
">Inactive</option>
<option value="
0
">Inactive</option>
</select>
</select>
</div>
</div>
<button class="
ui
button
" type="
submit
">Submit</button>
<button class="
ui
blue
button
" type="
submit
">Submit</button>
<button class="
ui
green
button
" type="
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
dashboard
.
senaraiProject
') }} '
;
">Back</button>
</form>
</form>
</div>
</div>
...
...
packages/portal/timesheet/resources/views/dashboard/penambahanProjectTeam.blade.php
View file @
1b125b1e
...
@@ -49,7 +49,7 @@
...
@@ -49,7 +49,7 @@
<div class="
field
">
<div class="
field
">
<label>Project Status</label>
<label>Project Status</label>
<select name="
status
" class="
ui
fluid
dropdown
">
<select name="
status
" class="
ui
fluid
dropdown
">
<
option value="">Project Team Status</option
>
<
!-- <option value="">Project Team Status</option> --
>
<option value="
1
">Active</option>
<option value="
1
">Active</option>
<option value="
0
">Inactive</option>
<option value="
0
">Inactive</option>
</select>
</select>
...
...
packages/portal/timesheet/resources/views/dashboard/senaraiProject.blade.php
View file @
1b125b1e
...
@@ -22,10 +22,10 @@
...
@@ -22,10 +22,10 @@
@foreach(
$projectlist
as
$key
=>
$project
)
@foreach(
$projectlist
as
$key
=>
$project
)
<tr>
<tr>
<td>
{
{$key+1}
}
</td>
<td>
{
{$key+1}
}
</td>
<td>
{
{
$project['projectcode']
}
}
</td>
<td>{{
data_get(
$project
,'projectcode')
}} </td>
<td>
{
{
$project['projectname']
}
}
</td>
<td>{{
data_get(
$project
,'projectname')
}} </td>
<td>
{
{
$project['projectmanager']
}
}
</td>
<td>{{
data_get(
$project
,'projectmanager')
}} </td>
<td>
{
{
$project['status']
}
}
</td>
<td>{{
data_get(
$project
,'status')
}} </td>
<td><a href="
{{
route
(
'timesheet::dashboard.senaraiProjectTeam'
,
[
'id'
=>
$project
[
'id'
]])
}}
">Project Team</a></td>
<td><a href="
{{
route
(
'timesheet::dashboard.senaraiProjectTeam'
,
[
'id'
=>
$project
[
'id'
]])
}}
">Project Team</a></td>
</tr>
</tr>
@endforeach
@endforeach
...
...
packages/portal/timesheet/routes/web.php
View file @
1b125b1e
...
@@ -9,8 +9,10 @@ Route::group(
...
@@ -9,8 +9,10 @@ Route::group(
],
],
function
()
{
function
()
{
//dashboard
Route
::
get
(
'home'
,[
'uses'
=>
'DashboardController@index'
,
'as'
=>
'dashboard.index'
]);
Route
::
get
(
'home'
,[
'uses'
=>
'DashboardController@index'
,
'as'
=>
'dashboard.index'
]);
//maintenance
Route
::
get
(
'senaraiProject'
,[
'uses'
=>
'DashboardController@senaraiProject'
,
'as'
=>
'dashboard.senaraiProject'
]);
Route
::
get
(
'senaraiProject'
,[
'uses'
=>
'DashboardController@senaraiProject'
,
'as'
=>
'dashboard.senaraiProject'
]);
Route
::
get
(
'penambahanProject'
,[
'uses'
=>
'DashboardController@penambahanProject'
,
'as'
=>
'dashboard.penambahanProject'
]);
Route
::
get
(
'penambahanProject'
,[
'uses'
=>
'DashboardController@penambahanProject'
,
'as'
=>
'dashboard.penambahanProject'
]);
Route
::
get
(
'senaraiProjectTeam'
,[
'uses'
=>
'DashboardController@senaraiProjectTeam'
,
'as'
=>
'dashboard.senaraiProjectTeam'
]);
Route
::
get
(
'senaraiProjectTeam'
,[
'uses'
=>
'DashboardController@senaraiProjectTeam'
,
'as'
=>
'dashboard.senaraiProjectTeam'
]);
...
@@ -29,14 +31,14 @@ Route::group(
...
@@ -29,14 +31,14 @@ Route::group(
Route
::
post
(
'updaterole'
,[
'uses'
=>
'DashboardController@updaterole'
,
'as'
=>
'dashboard.updaterole'
]);
Route
::
post
(
'updaterole'
,[
'uses'
=>
'DashboardController@updaterole'
,
'as'
=>
'dashboard.updaterole'
]);
// nonChargeableForm
// nonChargeableForm
Route
::
post
(
'addnonchargeabletask'
,[
'uses'
=>
'DashboardController@addnonchargeabletask'
,
'as'
=>
'dashboard.addnonchargeabletask'
]);
Route
::
post
(
'addnonchargeabletask'
,[
'uses'
=>
'DashboardController@addnonchargeabletask'
,
'as'
=>
'dashboard.addnonchargeabletask'
]);
// route to form
// route to form
Route
::
get
(
'chargeableForm'
,[
'uses'
=>
'DashboardController@chargeableForm'
,
'as'
=>
'dashboard.chargeableForm'
]);
Route
::
get
(
'chargeableForm'
,[
'uses'
=>
'DashboardController@chargeableForm'
,
'as'
=>
'dashboard.chargeableForm'
]);
Route
::
get
(
'nonChargeableForm'
,[
'uses'
=>
'DashboardController@nonChargeableForm'
,
'as'
=>
'dashboard.nonChargeableForm'
]);
Route
::
get
(
'nonChargeableForm'
,[
'uses'
=>
'DashboardController@nonChargeableForm'
,
'as'
=>
'dashboard.nonChargeableForm'
]);
Route
::
get
(
'overheadForm'
,[
'uses'
=>
'DashboardController@overheadForm'
,
'as'
=>
'dashboard.overheadForm'
]);
Route
::
get
(
'overheadForm'
,[
'uses'
=>
'DashboardController@overheadForm'
,
'as'
=>
'dashboard.overheadForm'
]);
//calendar
Route
::
get
(
'kalendarCharge'
,[
'uses'
=>
'DashboardController@kalendarCharge'
,
'as'
=>
'dashboard.kalendarCharge'
]);
Route
::
get
(
'kalendarCharge'
,[
'uses'
=>
'DashboardController@kalendarCharge'
,
'as'
=>
'dashboard.kalendarCharge'
]);
Route
::
get
(
'kalendarNonCharge'
,[
'uses'
=>
'DashboardController@kalendarNonCharge'
,
'as'
=>
'dashboard.kalendarNonCharge'
]);
Route
::
get
(
'kalendarNonCharge'
,[
'uses'
=>
'DashboardController@kalendarNonCharge'
,
'as'
=>
'dashboard.kalendarNonCharge'
]);
Route
::
get
(
'kalendar'
,[
'uses'
=>
'DashboardController@kalendar'
,
'as'
=>
'dashboard.kalendar'
]);
Route
::
get
(
'kalendar'
,[
'uses'
=>
'DashboardController@kalendar'
,
'as'
=>
'dashboard.kalendar'
]);
...
...
packages/portal/timesheet/src/Http/Controllers/DashboardController.php
View file @
1b125b1e
This diff is collapsed.
Click to expand it.
packages/portal/timesheet/src/Model/Project.php
View file @
1b125b1e
...
@@ -18,6 +18,11 @@ class Project extends Model
...
@@ -18,6 +18,11 @@ class Project extends Model
return
$this
->
hasOne
(
'Portal\Timesheet\Model\Staff_info'
,
'staff_id'
,
'p_project_task_team'
);
return
$this
->
hasOne
(
'Portal\Timesheet\Model\Staff_info'
,
'staff_id'
,
'p_project_task_team'
);
}
}
public
function
projectTeam
()
{
return
$this
->
hasOne
(
'Portal\Timesheet\Model\Pteam'
,
'fk_project_id'
,
'id'
);
}
/**
/**
* undocumented function
* undocumented function
*
*
...
...
packages/portal/timesheet/src/Model/Staff_info.php
View file @
1b125b1e
...
@@ -18,6 +18,11 @@ class Staff_info extends Model
...
@@ -18,6 +18,11 @@ class Staff_info extends Model
return
$this
->
hasMany
(
'Portal\Timesheet\Model\Department'
,
'id'
,
'fk_lkp_department'
);
return
$this
->
hasMany
(
'Portal\Timesheet\Model\Department'
,
'id'
,
'fk_lkp_department'
);
}
}
public
function
toUser
()
{
return
$this
->
hasOne
(
'Portal\Timesheet\Model\Users'
,
'u_staffID'
,
'staff_id'
);
}
// public function project_code()
// public function project_code()
// {
// {
// return $this->hasMany('Portal\Timesheet\Model\Ts_detail','td_project','id');
// return $this->hasMany('Portal\Timesheet\Model\Ts_detail','td_project','id');
...
...
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