fullheight.html 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <link href='../../dist/fullcalendar.css' rel='stylesheet' />
  5. <link href='../../dist/fullcalendar.print.css' rel='stylesheet' media='print' />
  6. <script src='../../node_modules/jquery/dist/jquery.js'></script>
  7. <script src='../../node_modules/moment/moment.js'></script>
  8. <script src='../../dist/fullcalendar.js'></script>
  9. <script>
  10. $(document).ready(function() {
  11. var date = new Date();
  12. var d = date.getDate();
  13. var m = date.getMonth();
  14. var y = date.getFullYear();
  15. $('#calendar').fullCalendar({
  16. header: {
  17. left: 'prev,next today',
  18. center: 'title',
  19. right: 'dayGridMonth,week,dayGridWeek,day,dayGridDay'
  20. },
  21. footer: {
  22. left: 'prev,next today',
  23. center: 'title',
  24. right: 'dayGridMonth,week,dayGridWeek,day,dayGridDay'
  25. },
  26. editable: true,
  27. events: [
  28. {
  29. title: 'All Day Event',
  30. start: new Date(y, m, 1)
  31. },
  32. {
  33. title: 'Long Event',
  34. start: new Date(y, m, d-5),
  35. end: new Date(y, m, d-2)
  36. },
  37. {
  38. groupId: 999,
  39. title: 'Repeating Event',
  40. start: new Date(y, m, d-3, 16, 0),
  41. allDay: false
  42. },
  43. {
  44. groupId: 999,
  45. title: 'Repeating Event',
  46. start: new Date(y, m, d+4, 16, 0),
  47. allDay: false
  48. },
  49. {
  50. title: 'Meeting',
  51. start: new Date(y, m, d, 10, 30),
  52. allDay: false
  53. },
  54. {
  55. title: 'Lunch',
  56. start: new Date(y, m, d, 12, 5),
  57. end: new Date(y, m, d, 14, 43),
  58. allDay: false
  59. },
  60. {
  61. title: 'Birthday Party',
  62. start: new Date(y, m, d+1, 19, 0),
  63. end: new Date(y, m, d+1, 22, 30),
  64. allDay: false
  65. },
  66. {
  67. title: 'Click for Google',
  68. start: new Date(y, m, 28),
  69. end: new Date(y, m, 29),
  70. url: 'http://google.com/'
  71. }
  72. ],
  73. fixedWeekCount: false,
  74. height: 'parent'
  75. });
  76. });
  77. </script>
  78. <style>
  79. html, body {
  80. margin: 0;
  81. padding: 0;
  82. height: 100%;
  83. }
  84. body {
  85. position: relative;
  86. font-size: 14px;
  87. font-family: "Lucida Grande",Helvetica,Arial,Verdana,sans-serif;
  88. }
  89. #calendar-wrap {
  90. position: absolute;
  91. top: 20px;
  92. right: 20px;
  93. bottom: 20px;
  94. left: 20px;
  95. }
  96. </style>
  97. </head>
  98. <body>
  99. <div id='calendar-wrap'>
  100. <div id='calendar'></div>
  101. </div>
  102. </body>
  103. </html>