Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
best-practical
rt-extension-jsgantt
Commits
78dba89d
Commit
78dba89d
authored
Oct 08, 2011
by
sunnavy
Browse files
fix the alignment problem in safari/chrome/ie8
see also
http://code.google.com/p/jsgantt/issues/detail?id=54
parent
c498cd8e
Changes
1
Hide whitespace changes
Inline
Side-by-side
html/NoAuth/js/jsgantt.js
View file @
78dba89d
...
...
@@ -1187,7 +1187,7 @@ Complete-Displays task percent complete</p>
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vTmpDate.getMinutes() + '</div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vTmpDate.setMinutes(vTmpDate.getMinutes() + 1);
}
...
...
@@ -1201,7 +1201,7 @@ Complete-Displays task percent complete</p>
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vTmpDate.getHours() + '</div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vTmpDate.setHours(vTmpDate.getHours() + 1);
}
...
...
@@ -1221,14 +1221,14 @@ Complete-Displays task percent complete</p>
if(vTmpDate.getDay() % 6 == 0) {
vDateRowStr += '<td class=
"
gheadwkend
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekendColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vTmpDate.getDate() + '</div></td>';
vItemRowStr += '<td class=
"
gheadwkend
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekendColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
> </div></td>';
vItemRowStr += '<td class=
"
gheadwkend
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekendColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
> </div></td>';
}
else {
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vTmpDate.getDate() + '</div></td>';
if( JSGantt.formatDateStr(vCurrDate,'mm/dd/yyyy') == JSGantt.formatDateStr(vTmpDate,'mm/dd/yyyy'))
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
cursor
:
default
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
}
vTmpDate.setDate(vTmpDate.getDate() + 1);
...
...
@@ -1254,9 +1254,9 @@ Complete-Displays task percent complete</p>
% }
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
} else {
% if ( RT->Config->Get('DateDayBeforeMonth') ) {
...
...
@@ -1266,9 +1266,9 @@ Complete-Displays task percent complete</p>
% }
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
}
...
...
@@ -1288,15 +1288,15 @@ Complete-Displays task percent complete</p>
if(vNxtDate <= vMaxDate) {
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center width:'+vColWidth+'px><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vMonthArr[vTmpDate.getMonth()].substr(0,3) + '</div></td>';
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
} else {
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center width:'+vColWidth+'px><div style=
"
width
:
'
+vColWidth+
'
px
"
>' + vMonthArr[vTmpDate.getMonth()].substr(0,3) + '</div></td>';
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
}
vTmpDate.setDate(vTmpDate.getDate() + 1);
...
...
@@ -1329,15 +1329,15 @@ Complete-Displays task percent complete</p>
if(vNxtDate <= vMaxDate) {
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center width:'+vColWidth+'px><div style=
"
width
:
'
+vColWidth+
'
px
"
>Qtr. ' + vQuarterArr[vTmpDate.getMonth()] + '</div></td>';
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
} else {
vDateRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
19
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center width:'+vColWidth+'px><div style=
"
width
:
'
+vColWidth+
'
px
"
>Qtr. ' + vQuarterArr[vTmpDate.getMonth()] + '</div></td>';
if( vCurrDate >= vTmpDate && vCurrDate < vNxtDate )
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
bgcolor=#' + vWeekdayColor + ' align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
else
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
vItemRowStr += '<td class=
"
ghead
"
style=
"
BORDER
-
TOP
:
#
efefef
1
px
solid
;
FONT
-
SIZE
:
12
px
;
HEIGHT
:
20
px
;
BORDER
-
LEFT
:
#
efefef
1
px
solid
;
BORDER
-
RIGHT
:
#
efefef
1
px
solid
;
"
align=center><div style=
"
width
:
'
+vColWidth+
'
px
"
>  </div></td>';
}
vTmpDate.setDate(vTmpDate.getDate() + 81);
...
...
Write
Preview
Supports
Markdown
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