summaryrefslogtreecommitdiffstats
path: root/template/en
diff options
context:
space:
mode:
authorbbaetz%student.usyd.edu.au <>2002-11-20 11:26:00 +0100
committerbbaetz%student.usyd.edu.au <>2002-11-20 11:26:00 +0100
commitbfd57984d5a0ba4e61d7d8bc296aa6caa1341857 (patch)
tree4ed91a5f3f6745e0833199c819414e9d45f616a0 /template/en
parent59006d0d200e21b1dadf184724a9f3d181302704 (diff)
downloadbugzilla-bfd57984d5a0ba4e61d7d8bc296aa6caa1341857.tar.gz
bugzilla-bfd57984d5a0ba4e61d7d8bc296aa6caa1341857.tar.xz
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
Diffstat (limited to 'template/en')
-rw-r--r--template/en/default/bug/edit.html.tmpl44
1 files changed, 23 insertions, 21 deletions
diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl
index 62e25f10a..575c0ea07 100644
--- a/template/en/default/bug/edit.html.tmpl
+++ b/template/en/default/bug/edit.html.tmpl
@@ -34,27 +34,29 @@
[% PROCESS bug/navigate.html.tmpl %]
[% PROCESS bug/time.html.tmpl %]
-<script type="text/javascript" language="JavaScript">
-<!--
-var fRemainingTime = [% bug.remaining_time %]; // holds the original value
-function adjustRemainingTime() {
- // subtracts time spent from remaining time
- var new_time;
-
- new_time =
- fRemainingTime - document.changeform.work_time.value;
- // get upto 2 decimal places
- document.changeform.remaining_time.value =
- Math.round(new_time * 100)/100;
-}
-
-function updateRemainingTime() {
- // if the remaining time is changed manually, update fRemainingTime
- fRemainingTime = document.changeform.remaining_time.value;
-}
-
-//-->
-</script>
+[% IF UserInGroup(Param('timetrackinggroup')) %]
+ <script type="text/javascript" language="JavaScript">
+ <!--
+ var fRemainingTime = [% bug.remaining_time %]; // holds the original value
+ function adjustRemainingTime() {
+ // subtracts time spent from remaining time
+ var new_time;
+
+ new_time =
+ fRemainingTime - document.changeform.work_time.value;
+ // get upto 2 decimal places
+ document.changeform.remaining_time.value =
+ Math.round(new_time * 100)/100;
+ }
+
+ function updateRemainingTime() {
+ // if the remaining time is changed manually, update fRemainingTime
+ fRemainingTime = document.changeform.remaining_time.value;
+ }
+
+ //-->
+ </script>
+[% END %]
<hr>