Это работает, когда мышь над ячейкой - она меняет цвет Но проблема в том, что с этим кодом обработка событий перестает работать, вроде события eventClick, определенное как: eventClick: function(calEvent, jsEvent, view) { // Triggered when the user clicks an event. http://fullcalendar.io/docs/mouse/eventClick/
Есть ли способ передавать все события в fullcalendar обьект, а не в таблицу нарисованную кодом выше?
You can post now and register later.
If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.
Актуальные контакты:
Telegram: @Nikker_web
E-Mail: tarasevich.email@gmail.com
Портфолио https://www.behance.net/d4d4186e
Разрабатываю дизайн групп в соц сетях, сайтов, приложений, другой дизайн под заказ
Актуальные контакты:
Telegram: @Nikker_web
E-Mail: tarasevich.email@gmail.com
Разрабатываю дизайн групп в соц сетях, сайтов, приложений, другой дизайн под заказ
Портфолио https://www.behance.net/d4d4186e
Question
mstdmstd
Всем привет,
Используя fullcalendar (http://arshaw.com/fullcalendar/) мне нужно установить цвет для 1ой ячейки под мышкой
Я нашел пример:
http://stackoverflow.com/questions/14128222/hover-effect-on-one-cell-of-agendaweek-fullcalendar
С кодом:
Paste this code after $('#calendar').fullCalendar( ... ); This will create addition TD in table $("table.fc-agenda-slots th").each(function () { $(this).width(50);});$("table.fc-agenda-slots td.fc-widget-content").each(function () { $(this).width(($("table.fc-agenda-days thead th.fc-col0").width())); $(this).after("<td class=\"fc-widget-content\"><div style=\"position:relative\"></div></td>"); $(this).after("<td class=\"fc-widget-content\" style=\"width:" + $("table.fc-agenda-days thead th.fc-col5").width() + "px\"><div style=\"position:relative\"></div></td>"); $(this).after("<td class=\"fc-widget-content\" style=\"width:" + $("table.fc-agenda-days thead th.fc-col4").width() + "px\"><div style=\"position:relative\"></div></td>"); $(this).after("<td class=\"fc-widget-content\" style=\"width:" + $("table.fc-agenda-days thead th.fc-col3").width() + "px\"><div style=\"position:relative\"></div></td>"); $(this).after("<td class=\"fc-widget-content\" style=\"width:" + $("table.fc-agenda-days thead th.fc-col2").width() + "px\"><div style=\"position:relative\"></div></td>"); $(this).after("<td class=\"fc-widget-content\" style=\"width:" + $("table.fc-agenda-days thead th.fc-col1").width() + "px\"><div style=\"position:relative\"></div></td>");});And this is the style css for hover:table.fc-agenda-slots td.fc-widget-content{ border-right: 1px #DDD solid;}table.fc-agenda-slots td.fc-widget-content:hover{ background-color: #F1F1F1;}Это работает, когда мышь над ячейкой - она меняет цвет
Но проблема в том, что с этим кодом обработка событий перестает работать, вроде события eventClick, определенное как:
eventClick: function(calEvent, jsEvent, view) { // Triggered when the user clicks an event. http://fullcalendar.io/docs/mouse/eventClick/
Есть ли способ передавать все события в fullcalendar обьект, а не в таблицу нарисованную кодом выше?
Спасибо!
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.