fullcalendar select 回调未在移动设备中触发

fullcalendar select callback not firing in mobile

我正在使用 fullcalendar 版本 2.9.1。我将日历呈现为 agendaWeek。当我从桌面点击特定时间段时,它会触发 select 回调,但当我点击移动设备时,它不会。有什么问题?

     selectable:true,
     select: function(start, end, jsEvent, view) {
      // event is firing this callback
     }

我在 angular 应用程序中使用 ui.calendar

我认为您需要点击并按住才能在移动设备中 select dates/slots...https://fullcalendar.io/docs/event_ui/longPressDelay/

看来你需要设置点击时间

longPressDelay: 1

例子

$('#calendar').fullCalendar
  height: 'auto'
  nowIndicator: true
  defaultView: gon.default_view
  header: ''
  selectable: true
  selectHelper: true
  longPressDelay: 1
  selectConstraint:
    start: '00:00'
    end: '24:00'
...