-
Notifications
You must be signed in to change notification settings - Fork 229
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
显示月份内容数据有问题 #71
Comments
在calendar.js中,找到方法getRightArr,改一下_length这一行即可 getRightArr(date) {
const arr = [];
const nextDate = this.getOtherMonth(date, 'nextMonth');
const leftLength = this.getDaysInOneMonth(date) + this.getMonthweek(date);
const _length = leftLength < 35 ? 14 - leftLength % 7 : 7 - leftLength % 7;
for (let i = 0; i < _length; i++) {
const nowTime = nextDate.getFullYear() + '/' + (nextDate.getMonth() + 1) + '/' + (i + 1);
arr.push({
id: i + 1,
date: nowTime,
isToday: false,
otherMonth: 'nextMonth',
});
}
return arr;
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
每月应该是显示42个数据,现在的代码有可能会显示35条,各位需要使用的注意点
The text was updated successfully, but these errors were encountered: