Bug 179293 - time tracking js should only appear if time tracking is

enabled patch by Jeff Hedlund <jeff.hedlund@matrixsi.com> r=bbaetz, a=justdave
parent 59006d0d
...@@ -34,10 +34,11 @@ ...@@ -34,10 +34,11 @@
[% PROCESS bug/navigate.html.tmpl %] [% PROCESS bug/navigate.html.tmpl %]
[% PROCESS bug/time.html.tmpl %] [% PROCESS bug/time.html.tmpl %]
<script type="text/javascript" language="JavaScript"> [% IF UserInGroup(Param('timetrackinggroup')) %]
<!-- <script type="text/javascript" language="JavaScript">
var fRemainingTime = [% bug.remaining_time %]; // holds the original value <!--
function adjustRemainingTime() { var fRemainingTime = [% bug.remaining_time %]; // holds the original value
function adjustRemainingTime() {
// subtracts time spent from remaining time // subtracts time spent from remaining time
var new_time; var new_time;
...@@ -46,15 +47,16 @@ function adjustRemainingTime() { ...@@ -46,15 +47,16 @@ function adjustRemainingTime() {
// get upto 2 decimal places // get upto 2 decimal places
document.changeform.remaining_time.value = document.changeform.remaining_time.value =
Math.round(new_time * 100)/100; Math.round(new_time * 100)/100;
} }
function updateRemainingTime() { function updateRemainingTime() {
// if the remaining time is changed manually, update fRemainingTime // if the remaining time is changed manually, update fRemainingTime
fRemainingTime = document.changeform.remaining_time.value; fRemainingTime = document.changeform.remaining_time.value;
} }
//--> //-->
</script> </script>
[% END %]
<hr> <hr>
......
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