fix error

This commit is contained in:
chiu 2020-08-14 22:43:11 +08:00
parent 3a0dffc1cb
commit 394374b1a6
2 changed files with 4 additions and 2 deletions

View File

@ -293,11 +293,12 @@
}
function toggle_event(ele,type){
$(ele).parents('.month_template').find('td').removeClass('w-calendar-toggle')
var toggle_month
if ($(ele).length==1){
$(ele).addClass('w-calendar-toggle')
toggle_data = $(ele).data('date-node')
toggle_month = $(ele).data('date-node').split('-')[1]
}
var toggle_month = $(ele).data('date-node').split('-')[1]
if (toggle_month==month || $(ele).length!=1){
if (type=='show'){
show_event($(ele).data('date-node'),ele)

View File

@ -432,11 +432,12 @@
}
function toggle_event(ele,type){
$(ele).parents('.month_template').find('td').removeClass('w-calendar-toggle')
var toggle_month
if ($(ele).length==1){
$(ele).addClass('w-calendar-toggle')
toggle_data = $(ele).data('date-node')
toggle_month = $(ele).data('date-node').split('-')[1]
}
var toggle_month = $(ele).data('date-node').split('-')[1]
if (toggle_month==month || $(ele).length!=1){
if (type=='show'){
show_event($(ele).data('date-node'),ele)