2010-08-24 5 views
0

어떤 이유로 fullCalendar는 basicDay보기에서 7PM 이후에 발생하는 이벤트를 표시하지 않습니다. 이벤트가 월보기에 표시되지만 기본 일보기에는 표시되지 않습니다.Gcal의 FullCalendar는 기본보기에서 오후 7시 이후에 이벤트를 표시하지 않습니다.

의견을 보내 주시면 감사하겠습니다.

여기 내 코드입니다. 같은 페이지에 두 개의 캘린더가 있습니다. 첫 번째는 월보기이며 두 번째는 basicDay보기입니다.

$(document).ready(function() { 

    // page is now ready, initialize the calendar... 

    $('#calendar').fullCalendar({ 
    weekMode:'variable', 
    events: $.fullCalendar.gcalFeed(
    "http://www.google.com/calendar/feeds/google_account/public/basic" 
    ), 
    eventClick: function(event) { 
    if (event.url) { 
    window.open(event.url,"_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=750, height=450"); 
    return false; 
    } 
    } 
    }); 

    $('#calendar_min').fullCalendar({ 
    height:193, 
    header:false, 
     defaultView: 'basicDay', 
    events: $.fullCalendar.gcalFeed(
    "http://www.google.com/calendar/feeds/google_account/public/basic" 
    ), 
    eventClick: function(event) { 
    if (event.url) { 
    window.open(event.url,"_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=750, height=450"); 
    return false; 
    } 
    } 
    }); 
}); 

답변

0

어떤 오류가 발생합니까? 오후 7시 이후에 Google 피드를 이벤트로 바꾸면 정상적으로 표시됩니다. (귀하의 예에는 여분이 있음에도 불구하고)}; 그걸 제거해야합니다.

 $('#calendar_min').fullCalendar({ 
      height: 193, 
      header: false, 
      defaultView: 'basicDay', 
      events: [ 
      { 
       title: 'Day', 
       start: new Date(y, m, d, 20), 
       end: new Date(y, m, d, 21), 
       description: 'long description3', 
       id: 2 
      }], 
      eventClick: function(event) { 
       if (event.url) { 
        window.open(event.url, "_blank", "toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=750, height=450"); 
        return false; 
       } 
      } 
     }); 
1

이것은 사용자가 EST에 있기 때문에 발생합니다. 새 이벤트를 만들 때 시간은 GMT 오전 12:00이므로 -5 시간 = 오후 7시입니다. ignoreTimezone을 사용하여 보길 원할 수도 있습니다. http://arshaw.com/fullcalendar/docs/event_data/

0

비슷한 문제가 있습니다. Google 캘린더 표준 시간대가 EDT 였고 이벤트의 마지막 4 시간이 디스플레이에서 누락되었습니다.

fetchAndRenderEvents()를 fullcalendar.js (849 행)로 변경하여 문제를 해결했습니다.

그것은이었다

function fetchAndRenderEvents() { 
     fetchEvents(currentView.start, currentView.end); 
      // ... will call reportEvents 
      // ... which will call renderEvents 
    } 

나는 currentView.end

function fetchAndRenderEvents() { 
    // Add 1 day to end to ensure all events are fetched when the time zone is applied. 
    fetchEvents(currentView.start, currentView.end.add(1, 'days')); 
     // ... will call reportEvents 
     // ... which will call renderEvents 
} 
에 하루 추가
관련 문제