Commit da36a40a by liang ce

index修改

parent a45cb9de
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<block a:elif="{{item.type == 'week'}}"> <block a:elif="{{item.type == 'week'}}">
<view class="week"> <view class="week">
<view class="manyWeeks"> <view class="manyWeeks">
第49周,12月1日 - 7日 {{item.value}}
</view> </view>
</view> </view>
</block> </block>
......
...@@ -94,7 +94,6 @@ Page({ ...@@ -94,7 +94,6 @@ Page({
} }
} }
let DateList = []; let DateList = [];
let listYear = '';
let listMonth = ''; let listMonth = '';
let listWeek = new Date(year, 0, 1).getDay() === 0 ? 0 : 1; let listWeek = new Date(year, 0, 1).getDay() === 0 ? 0 : 1;
DateList.push({ DateList.push({
...@@ -102,6 +101,7 @@ Page({ ...@@ -102,6 +101,7 @@ Page({
value: year value: year
}) })
DateMap.forEach(function (value, key, map) { DateMap.forEach(function (value, key, map) {
console.log(key)
if (new Date(key).getDay() === 0 && that.count(new Date(key), new Date(year, 0, isLeapYear ? 366 : 365) >= 7)) { if (new Date(key).getDay() === 0 && that.count(new Date(key), new Date(year, 0, isLeapYear ? 366 : 365) >= 7)) {
listWeek = listWeek + 1 listWeek = listWeek + 1
if (new Date(key).getMonth() !== listMonth) { if (new Date(key).getMonth() !== listMonth) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment