Created
June 12, 2019 13:19
-
-
Save wilcorrea/c9727ee2775d34c0f07d10399385907f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { Calendar } from '@fullcalendar/core'; | |
| import dayGridPlugin from '@fullcalendar/daygrid'; | |
| const calendar = { | |
| loadEventos() { | |
| AppCompromissos.showTabAgenda(); | |
| AppCompromissos.showCalendar(); | |
| }, | |
| showTabAgenda(){ | |
| $(".nav-tabs a").click(function(){ | |
| $(this).tab('show'); | |
| }); | |
| }, | |
| showCalendar(){ | |
| document.addEventListener('DOMContentLoaded', function() { | |
| var calendarEl = document.getElementById('calendar'); | |
| var calendar = new Calendar(calendarEl, { | |
| plugins: [ dayGridPlugin ] | |
| }); | |
| calendar.render(); | |
| }); | |
| } | |
| } | |
| $(document).ready(function () { | |
| calendar.loadEventos(); | |
| }); | |
| module.exports = calendar; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment