Calendar previous and next month buttons do not load the months

Created on 25 April 2024, 2 months ago
Updated 26 April 2024, 2 months ago

Whenever I hit the next or previous buttons on the calendar view, I get this error in my console and the Calendar stays on the current month.

Uncaught TypeError: Cannot read properties of null (reading 'removeAttribute')
at Drupal.Message.defaultWrapper (message.js?v=10.2.3:43:17)
at new Drupal.Message (message.js?v=10.2.3:26:46)
at new Drupal.AjaxError (ajax.js?v=10.2.3:184:35)
at Drupal.Ajax.error (ajax.js?v=10.2.3:1219:11)
at Object.complete (ajax.js?v=10.2.3:608:23)
at c (jquery.min.js?v=3.7.1:2:25304)
at Object.fireWith (jquery.min.js?v=3.7.1:2:26053)
at l (jquery.min.js?v=3.7.1:2:77910)
at XMLHttpRequest. (jquery.min.js?v=3.7.1:2:80265)

πŸ› Bug report
Status

Closed: works as designed

Version

2.1

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @ryanknighton
  • Does this happen with the same view but a different format - such as Table or Unformatted list?

  • This happens with the same view and different formats. I am using the Calendar By Month view. It works in the view preview page but not the website page itself.

  • πŸ‡ΊπŸ‡ΈUnited States micnap

    Same issue for me. Using the Month format and have unchecked the "Use "Previous/Next" labels" checkbox in the Pager settings. The previous and next links show as the previous and next month names in the view preview. But on the actual page with the calendar, they still show as Previous and Next.

  • Status changed to Postponed: needs info 2 months ago
  • Several information I m not sure I understand here, sorry.

    @ryanknighton can you try with a different view style, such as Table or Unformatted list please ?

    If the problem occurs with a totally different view style - not a Calendar View display - therefore it is not related to this module. It will be related to your theme or something on your frontend - plus you said everything work in preview on the back. I am quite sure your Ajax issue is not related to Calendar. Looking forward to hearing from you.

    @micnap I think this is a totally different issue. Do you mind opening a bug report? Please give details about your version of the Calendar View module and your view configuration - I do not reproduce the issue on the dev branch thus I guess you might be using an old release. Thanks.

  • This problem occurs with table, unformatted list, grid, etc. And like I said, it does work in preview mode so it must be something on my end. That helps me. I'll dig around deeper and see what I can find. Thanks!

  • This is resolved. I had to turn off Use Ajax in the view. I'm an idiot. Thanks for all your help @matthieuscarset!

  • Status changed to Closed: works as designed 2 months ago
Production build 0.69.0 2024