提交 b18b5058 编写于 作者: S sushuang

Fix #8045 (The last day of a month was not displayed).

上级 f9281197
......@@ -181,7 +181,10 @@ Calendar.prototype = {
var date = dayInfo.formatedDate;
// if not in range return [NaN, NaN]
if (clamp && !(dayInfo.time >= range.start.time && dayInfo.time <= range.end.time)) {
if (clamp && !(
dayInfo.time >= range.start.time
&& dayInfo.time < range.end.time + PROXIMATE_ONE_DAY
)) {
return [NaN, NaN];
}
......
......@@ -20,6 +20,7 @@
var graphData = [
[
// This is the first day of Feb
1485878400000,
260
],
......@@ -46,6 +47,11 @@
[
1488124800000,
985
],
[
// This is the last day of Feb. See #8045
1488240000000,
371
]
];
......@@ -59,15 +65,6 @@
require([
'echarts'
// 'echarts/chart/heatmap',
// 'echarts/chart/scatter',
// 'echarts/chart/effectScatter',
// 'echarts/chart/graph',
// 'echarts/component/title',
// 'echarts/component/legend',
// 'echarts/component/calendar',
// 'echarts/component/tooltip',
// 'echarts/component/visualMap'
], function (echarts) {
var chart = echarts.init(document.getElementById('main'));
......@@ -89,6 +86,7 @@
series: {
type: 'graph',
// type: 'scatter',
edgeSymbol: ['none', 'arrow'],
coordinateSystem: 'calendar',
links: links,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册