<scroll-view class="scroll-view_H" scroll-x>
<view class='list' style='width:{
{ width }}rpx'>
<view bindtap="select" wx:for="{
{ calendar }}" wx:key="" wx:for-item="item" wx:for-index="index" data-index="{
{ index }}" class='listItem {
{index==currentIndex? "current":""}}'>
<text class='name'>{
{ item.week }}</text>
<text class='date'>{
{ item.date }}</text>
</view>
</view>
</scroll-view>
function getThisMonthDays(year, month) {
return new Date(year, month, 0).getDate();
}
// 计算每月第一天是星期几
function getFirstDayOfWeek(year, month) {
return new