[Rt-commit] r18564 - in rt/3.8/trunk: . etc
sartak at bestpractical.com
sartak at bestpractical.com
Tue Feb 24 17:33:01 EST 2009
Author: sartak
Date: Tue Feb 24 17:33:00 2009
New Revision: 18564
Modified:
rt/3.8/trunk/ (props changed)
rt/3.8/trunk/etc/RT_Config.pm.in
rt/3.8/trunk/share/html/Elements/SelectTimeUnits
Log:
r80502 at onn: sartak | 2009-02-24 17:32:48 -0500
New preference $DefaultTimeUnitsToHours for setting the default time units
Modified: rt/3.8/trunk/etc/RT_Config.pm.in
==============================================================================
--- rt/3.8/trunk/etc/RT_Config.pm.in (original)
+++ rt/3.8/trunk/etc/RT_Config.pm.in Tue Feb 24 17:33:00 2009
@@ -1215,6 +1215,14 @@
#Set($DefaultQueue, 'General');
+=item C<$DefaultTimeUnitsToHours>
+
+Use this to set the default units for time entry to hours instead of minutes.
+
+=cut
+
+Set($DefaultTimeUnitsToHours, 0);
+
=back
=head1 L<Net::Server> (rt-server) Configuration
Modified: rt/3.8/trunk/share/html/Elements/SelectTimeUnits
==============================================================================
--- rt/3.8/trunk/share/html/Elements/SelectTimeUnits (original)
+++ rt/3.8/trunk/share/html/Elements/SelectTimeUnits Tue Feb 24 17:33:00 2009
@@ -46,11 +46,16 @@
%#
%# END BPS TAGGED BLOCK }}}
<select class="TimeUnits" id="<% $Name %>" name="<% $Name %>">
-<option value="minutes" selected="selected"><% loc('Minutes') %></option>
-<option value="hours"><% loc('Hours') %></option>
+<option value="minutes" <% $HoursDefault ? '' : 'selected="selected"' |n%>>
+ <% loc('Minutes') %>
+</option>
+<option value="hours" <% $HoursDefault ? 'selected="selected"' : '' |n%>>
+ <% loc('Hours') %>
+</option>
</select>
<%INIT>
$Name .= '-TimeUnits' unless $Name =~ /-TimeUnits$/io;
+my $HoursDefault = RT->Config->Get('DefaultTimeUnitsToHours');
</%INIT>
<%ARGS>
$Name => ''
More information about the Rt-commit
mailing list