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
9b69e786
Commit
9b69e786
authored
Apr 15, 2024
by
Azhan Hannan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixing timesheet overhead and chargeable form
parent
f9fe6c4b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
49 additions
and
10 deletions
+49
-10
packages/portal/timesheet/resources/views/form/chargeableForm.blade.php
+23
-5
packages/portal/timesheet/resources/views/form/overheadForm.blade.php
+26
-5
No files found.
packages/portal/timesheet/resources/views/form/chargeableForm.blade.php
View file @
9b69e786
...
@@ -369,7 +369,7 @@ input[type=number] {
...
@@ -369,7 +369,7 @@ input[type=number] {
@
endfor
@
endfor
@
else
@
else
@
for
(
$i
=
15
+
count
(
$lat
)
;
$i
<
$daymonth
;
$i
++
)
@
for
(
$i
=
15
;
$i
<
$daymonth
;
$i
++
)
{{
--
<
th
class
="
center
aligned
">{{
$strdays[$i]
}}</th> --}}
{{
--
<
th
class
="
center
aligned
">{{
$strdays[$i]
}}</th> --}}
@php
@php
...
@@ -473,9 +473,13 @@ input[type=number] {
...
@@ -473,9 +473,13 @@ input[type=number] {
@
endfor
@
endfor
@
else
@
else
@
for
(
$i
=
15
+
count
(
$lat
);
$i
<
$daymonth
;
$i
++
)
@
for
(
$i
=
15
;
$i
<
$daymonth
;
$i
++
)
@
php
$filteredData
=
$lat
->
filter
(
function
(
$item
)
use
(
$i
)
{
return
date
(
'd'
,
strtotime
(
$item
[
'DATE'
]))
==
$i
+
1
;
});
<?
php
$valuehour
=
''
;
$valuehour
=
''
;
$date
=
$year
.
'-'
.
sprintf
(
'%02d'
,
$month
)
.
'-'
.
sprintf
(
'%02d'
,
$i
+
1
);
$date
=
$year
.
'-'
.
sprintf
(
'%02d'
,
$month
)
.
'-'
.
sprintf
(
'%02d'
,
$i
+
1
);
...
@@ -488,11 +492,25 @@ input[type=number] {
...
@@ -488,11 +492,25 @@ input[type=number] {
$total
+=
data_get
(
$valuehour
,
'td_hours'
);
$total
+=
data_get
(
$valuehour
,
'td_hours'
);
}
}
?>
@
endphp
<td>
@
if
(
$filteredData
->
isEmpty
())
<
td
class
="
center
aligned
">
<input class="
center
aligned
" 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
']}}'
);
">
</td>
@else
@foreach(
$filteredData
as
$key
=>
$date
)
@if(data_get(
$date
,'attendance_status') == 1)
<td class="
center
aligned
">
<input class="
center
aligned
" 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 class="
center
aligned
" 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
']}}'
);
">
</td>
</td>
@else
<td class="
center
aligned
" style="
background
-
color
:
#DCDCDC;">
<
input
class
="
center
aligned
" 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
;
background
-
color
:
#DCDCDC;" onchange="limiter(this,'{{$project['td_project']}}');">
</
td
>
@
endif
@
endforeach
@
endif
@
endfor
@
endfor
@
endif
@
endif
@
else
@
else
...
...
packages/portal/timesheet/resources/views/form/overheadForm.blade.php
View file @
9b69e786
...
@@ -382,7 +382,7 @@ input[type=number] {
...
@@ -382,7 +382,7 @@ input[type=number] {
@
endif
@
endif
@
endfor
@
endfor
@
else
@
else
@
for
(
$i
=
15
+
count
(
$lat
)
;
$i
<
$daymonth
;
$i
++
)
@
for
(
$i
=
15
;
$i
<
$daymonth
;
$i
++
)
{{
--
<
th
class
="
center
aligned
">{{
$strdays[$i]
}}</th> --}}
{{
--
<
th
class
="
center
aligned
">{{
$strdays[$i]
}}</th> --}}
@php
@php
...
@@ -438,6 +438,7 @@ input[type=number] {
...
@@ -438,6 +438,7 @@ input[type=number] {
</td>
</td>
@if(count(
$lat
) > 0)
@if(count(
$lat
) > 0)
@if(
$phase
== 1)
@if(
$phase
== 1)
@for(
$i
= 0;
$i
< 15 ;
$i
++)
@for(
$i
= 0;
$i
< 15 ;
$i
++)
...
@@ -481,8 +482,13 @@ input[type=number] {
...
@@ -481,8 +482,13 @@ input[type=number] {
@
endif
@
endif
@
endfor
@
endfor
@
else
@
else
@
for
(
$i
=
15
+
count
(
$lat
);
$i
<
$daymonth
;
$i
++
)
@
for
(
$i
=
15
;
$i
<
$daymonth
;
$i
++
)
<?
php
@
php
$filteredData
=
$lat
->
filter
(
function
(
$item
)
use
(
$i
)
{
return
date
(
'd'
,
strtotime
(
$item
[
'DATE'
]))
==
$i
+
1
;
});
$valuehour
=
''
;
$valuehour
=
''
;
$date
=
$year
.
'-'
.
sprintf
(
'%02d'
,
$month
)
.
'-'
.
sprintf
(
'%02d'
,
$i
+
1
);
$date
=
$year
.
'-'
.
sprintf
(
'%02d'
,
$month
)
.
'-'
.
sprintf
(
'%02d'
,
$i
+
1
);
...
@@ -495,10 +501,25 @@ input[type=number] {
...
@@ -495,10 +501,25 @@ input[type=number] {
$total
+=
data_get
(
$valuehour
,
'td_hours'
);
$total
+=
data_get
(
$valuehour
,
'td_hours'
);
}
}
?>
@
endphp
<td>
@
if
(
$filteredData
->
isEmpty
())
<
th
class
="
center
aligned
">
{{
$strdays[$i]
}}
</th>
@else
@foreach(
$filteredData
as
$key
=>
$date
)
@if(data_get(
$date
,'attendance_status') == 1)
<td class="
center
aligned
">
<input type="
text
" onkeypress="
onlynumber
(
event
)
" id="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" name="
hour
[{{
$project
[
'td_project'
]}}][{{
$i
+
1
}}]
" value="
@
if
(
$valuehour
){{
data_get
(
$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
){{
data_get
(
$valuehour
,
'td_hours'
)}}
@
else
@
endif
" min="
0
" max="
24
" style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
</td>
</td>
@else
<td class="
center
aligned
" style="
background
-
color
:
#DCDCDC;">
<
input
type
=
"text"
onkeypress
=
"onlynumber(event)"
id
=
"hour[
{
{$project['td_project']}}][{{$i+1}
}
]"
name
=
"hour[
{
{$project['td_project']}}][{{$i+1}
}
]"
value
=
"@if(
$valuehour
)
{
{data_get($valuehour,'td_hours')}
}
@else @endif"
min
=
"0"
max
=
"24"
style
=
"padding:2px;margin:unset;background-color: #DCDCDC;"
onchange
=
"limiter(this,'
{
{$project['td_project']}
}
');"
>
</
td
>
@
endif
@
endforeach
@
endif
@
endfor
@
endfor
@
endif
@
endif
@
else
@
else
...
...
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