Skip to content

Commit

Permalink
test: update example
Browse files Browse the repository at this point in the history
  • Loading branch information
付登荣 committed Aug 10, 2019
1 parent 21aca3f commit ff06604
Showing 1 changed file with 5 additions and 15 deletions.
20 changes: 5 additions & 15 deletions src/pages/calendarComponent/index.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,12 @@
const conf = {
data: {
calendarConfig: {
// multi: true,
// inverse: 1, // 单选模式下是否可以取消选择
// defaultDay: '2019-5-19'
onlyShowCurrentMonth: 1
// disablePastDay: 1
}
},
onShow: function() {
// initCalendar();
this.setTodo();
calendarConfig: {}
},
setTodo() {
const data = [
{
year: '2019',
month: '7',
month: '8',
day: '15'
},
{
Expand All @@ -29,12 +19,11 @@ const conf = {
// 异步请求
setTimeout(() => {
this.calendar.setTodoLabels({
circle: true,
// pos: 'top',
// showLabelAlways: true,
days: data
});
}, 1000);
this.calendar.enableArea(['2019-5-7', '2019-10-28']);
this.calendar.enableArea(['2019-8-7', '2019-9-28']);
},
afterTapDay(e) {
console.log('afterTapDay', e.detail);
Expand All @@ -46,6 +35,7 @@ const conf = {
console.log('onTapDay', e.detail);
},
afterCalendarRender(e) {
this.setTodo();
console.log('afterCalendarRender', e);
}
};
Expand Down

0 comments on commit ff06604

Please sign in to comment.