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
48322c1b
Commit
48322c1b
authored
Oct 31, 2022
by
Azhan Hannan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
changes chargeable form
parent
2c8b58a1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
41 deletions
+20
-41
packages/portal/timesheet/resources/views/form/chargeableForm.blade.php
+19
-40
packages/portal/timesheet/resources/views/form/overheadForm.blade.php
+1
-1
No files found.
packages/portal/timesheet/resources/views/form/chargeableForm.blade.php
View file @
48322c1b
...
...
@@ -155,44 +155,20 @@ input[type=number] {
->first();
$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
']}}'
);
">
</td>
@endfor
@endif
<td>
<input class="
center
aligned
" type="
text
" name="
total
-
{{
$project
[
'td_project'
]}}
" id="
total
-
{{
$key
+
1
}}
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
" readonly="
readonly
" value=
{
{$total}
}
>
<input class="
center
aligned
" type="
text
" name="
total
-
{{
$project
[
'td_project'
]}}
" id="
total
-
{{
$key
+
1
}}
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
"
onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
"
readonly="
readonly
" value=
{
{$total}
}
>
</td>
</tr>
<?php
$all
+=
$total
; ?>
@endforeach
</tbody>
<!-- <tfoot>
<tr>
<th colspan="
2
">
Total Hours
</th>
@if(
$phase
== 1)
@for(
$i
= 0;
$i
< 15 ;
$i
++)
<th>
<input class="
center
aligned
" type="
text
" name="
thour
-
{{
$project
[
'td_project'
]}}
" id="
thours
[{{
$i
+
1
}}][{{
$key
+
1
}}]
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
" readonly="
readonly
" value="
{{
$cday
[
$i
]}}
">
</th>
@endfor
@else
@for(
$i
= 15;
$i
<
$daymonth
;
$i
++)
<th>
<input class="
center
aligned
" type="
text
" name="
thour
-
{{
$project
[
'td_project'
]}}
" id="
thours
[{{
$i
+
1
}}][{{
$key
+
1
}}]
" style="
padding
-
right
:
4
px
;
padding
-
left
:
4
px
;
" readonly="
readonly
" value="
{{
$cday
[
$i
]}}
">
</th>
@endfor
@endif
<th>
<input class="
center
aligned
" type="
text
" onkeypress="
onlynumber
(
event
)
" name="
all
" id="
all
" readonly="
readonly
" value="
{{
$all
}}
">
</th>
</tr>
</tfoot> -->
</table>
@if(
$projectlist
== [])
<button type="
submit
" class="
ui
right
floated
aligned
ui
blue
compact
labeled
icon
button
">
...
...
@@ -238,7 +214,7 @@ input[type=number] {
});
function limiter(input,pid
,lasttd,key
) {
function limiter(input,pid) {
var currenttotal = 0;
var all = 0;
...
...
@@ -281,18 +257,21 @@ input[type=number] {
}
// console.log("
currenttotal
-->
" + currenttotal);
document.getElementById('total-'+key).value = currenttotal;
var y = 0;
for(var j = 1; j < key+1; j++){
var allid = document.getElementById('total-'+j);
if (document.getElementById('total-'+j)) {
y = document.getElementById('total-'+j).value;
value = parseFloat(parseFloat(y).toFixed(1));
all += value;
}
}
console.log(all);
document.getElementById('all').value = all;
document.getElementById('total-'+pid).value = currenttotal;
// var y = 0;
// for(var j = 1; j < key+1; j++){
// var allid = document.getElementById('total-'+j);
// if (document.getElementById('total-'+j)) {
// y = document.getElementById('total-'+j).value;
// value = parseFloat(parseFloat(y).toFixed(1));
// // all += value;
// }
// }
// console.log(all);
// document.getElementById('all').value = all;
// document.getElementById('total-'+pid).value = currenttotal;
}
</script>
...
...
packages/portal/timesheet/resources/views/form/overheadForm.blade.php
View file @
48322c1b
...
...
@@ -147,7 +147,7 @@ input[type=number] {
$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
){{
data_get
(
$valuehour
,
'td_hours'
)}}
@
else
@
endif
" min="
0
" max="
24
" style="
padding
:
2
px
;
margin
:
unset
" onchange="
limiter
(
this
,
'{{$project['
td_project
']}}'
);
">
</td>
@endfor
...
...
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