[Rt-commit] r3482 - in rt/branches/3.5-TESTING: . html/Helpers
trs at bestpractical.com
trs at bestpractical.com
Sat Jul 16 15:38:01 EDT 2005
Author: trs
Date: Sat Jul 16 15:38:00 2005
New Revision: 3482
Modified:
rt/branches/3.5-TESTING/ (props changed)
rt/branches/3.5-TESTING/html/Helpers/CalPopup.html
Log:
r5011 at wintermute: tom | 2005-07-16 15:34:30 -0400
Fixed CHALDEA bug from ticket #6846. Slightly different fix than Kevin Falcone's in the ticket.
Modified: rt/branches/3.5-TESTING/html/Helpers/CalPopup.html
==============================================================================
--- rt/branches/3.5-TESTING/html/Helpers/CalPopup.html (original)
+++ rt/branches/3.5-TESTING/html/Helpers/CalPopup.html Sat Jul 16 15:38:00 2005
@@ -9,7 +9,7 @@
<table>
<caption>
<a class="prev" href="CalPopup.html?DisplayedMonth=<%$prev_month%>&DisplayedYear=<%$prev_year%>&field=<%$field%>"><&|/l&>Prev</&></a>
- <span class="month"><% $months[$DisplayedMonth] %> <% $DisplayedYear %></span>
+ <span class="month"><% $months[$DisplayedMonth-1] %> <% $DisplayedYear %></span>
<a class="next" href="CalPopup.html?DisplayedMonth=<%$next_month%>&DisplayedYear=<%$next_year%>&field=<%$field%>"><&|/l&>Next</&></a>
</caption>
<tr>
@@ -22,7 +22,7 @@
% foreach my $day (@{$week}) {
<td>
% if ($day) {
-% my $datestr = sprintf('%04d-%02d-%02d', $DisplayedYear, $DisplayedMonth+1, $day);
+% my $datestr = sprintf('%04d-%02d-%02d', $DisplayedYear, $DisplayedMonth, $day);
<a href="#" onclick="updateParentField('<% $field %>','<% $datestr %>'); return false;"><% $day %></a>
% } else {
@@ -48,9 +48,9 @@
September October November December);
unless ($DisplayedYear) {
- $DisplayedMonth = $today[4];
+ $DisplayedMonth = $today[4] + 1;
$DisplayedYear = ($today[5] + 1900);
-}
+}
my ($prev_year, $next_year, $prev_month, $next_month);
$prev_month = $next_month = $DisplayedMonth;
@@ -59,12 +59,12 @@
$next_month++;
$prev_month--;
-if ($DisplayedMonth == 11) {
+if ($DisplayedMonth == 12) {
$next_year++;
- $next_month = 0;
+ $next_month = 1;
}
-elsif ($DisplayedMonth == 0) {
- $prev_month = 11;
+elsif ($DisplayedMonth == 1) {
+ $prev_month = 12;
$prev_year--;
}
More information about the Rt-commit
mailing list