• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

MMM-CalendarExt3 BST Timezone issue

Scheduled Pinned Locked Moved Solved Troubleshooting
26 Posts 4 Posters 3.5k Views 4 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Away
    sdetweil @MMRIZE
    last edited by Apr 9, 2024, 5:59 PM

    @MMRIZE but… for full day, you ignore the time… or reset it to 00:00:00

    Sam

    How to add modules

    learning how to use browser developers window for css changes

    M 1 Reply Last reply Apr 9, 2024, 6:08 PM Reply Quote 0
    • M Offline
      MMRIZE @sdetweil
      last edited by MMRIZE Apr 9, 2024, 6:11 PM Apr 9, 2024, 6:08 PM

      @sdetweil
      Of course I can. I have already provided that manual method to my CX3 users. (https://github.com/MMRIZE/MMM-CalendarExt3/wiki/To-fix-wrong-repeated-fullday-event-displaying-(MM-2.27))

      However, the value of notification should be trustable or consistent. All other kinds of events, like In-A-Day single events, Multiday-but-not-fullday-event, and even Repeated-Not-Fullday-event, could deliver the proper time, but only Repeated-Fullday events delivered the wrong value. That is out of common sense.

      At least, it should have been guided as an intentional design. (I wasted several hours trying to guess what happened. Who could imagine the notification value was wrong?)

      PS. Ah, I forgot there was another case; imperial units on broadcasted weather information. :)

      S 1 Reply Last reply Apr 9, 2024, 6:17 PM Reply Quote 0
      • S Away
        sdetweil @MMRIZE
        last edited by Apr 9, 2024, 6:17 PM

        @MMRIZE yes, we have had other users making updates.

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 Reply Last reply Reply Quote 0
        • S Offline
          shall_ @MMRIZE
          last edited by Apr 11, 2024, 1:33 AM

          @MMRIZE Apologies for the delayed reply, i have been busy and then couldn’t log in to the forum.

          I have tried updating, installing, and reinstalling. then adding the code into my config file but i still can’t get it to correct. I think i put the code in correctly but i have attached that so you can check. my config file isn’t throwing up any errors?

          how do i check what version of CX3 i am running? i did delete the whole folder and redo the git pull/install so i should have whatever is on github?

          {
          			module: "MMM-CalendarExt3",
          			position: "bottom_bar",
          			title: "",
          			config: {
          			mode: "week", //week or month view
          			weeksInView: 5,
          			weekIndex: 0, //-1 start last week, 0 this week, 1 next week.
          			instanceId: "basicCalendar",
          			locale: 'en-GB',
          			maxEventLines: 4,
          			firstDayOfWeek: 1,
          			useWeather: true,
          			weatherLocationName: 'xxxx',
          			
          
          			eventPayload: (payload) => {
          				for (let ev of payload) {
          				  if (ev.fullDayEvent) {
          					let gap = +ev.endDate - +ev.startDate
          					if (gap % (1000 * 60 * 60 * 24) === 0) {
          					  ev.startDate = new Date(+ev.startDate).setHours(0, 0, 0, 0)
          					  ev.endDate = new Date(+ev.startDate + gap).setMilliseconds(-1)
          					}
          				  }
          				}
          				return payload
          			  },
          
          			eventTransformer: (e) => {
            e.startDate = new Date(e.start?.date || e.start?.dateTime).valueOf()
            e.endDate = new Date(e.end?.date || e.end?.dateTime).valueOf()
            e.title = e.summary
            e.fullDayEvent = (e.start?.date) ? true : false
            //return e
          
          	if (e.title.search('Lates') > -1) e.color = 'mediumvioletred'
          	if (e.title.search('Earlies') > -1) e.color = 'yellow'
          	if (e.title.search('12 hours') > -1) e.color = 'blue'
          	if (e.title.search('12 Hours') > -1) e.color = 'blue'
          	if (e.title.search('12 hrs') > -1) e.color = 'blue'
          	if (e.title.search('Vacation') > -1) e.color = 'blue'
          	if (e.title.search('vacation') > -1) e.color = 'blue'
          	if (e.title.search('Shutdown') > -1) e.color = 'goldenrod'
          	if (e.title.search('My weekend') > -1) e.color = 'deepskyblue'
          
          	
          	
            return e
          	 
          
          
          }
          
          }
          		},
          
          M S 2 Replies Last reply Apr 11, 2024, 4:55 AM Reply Quote 0
          • M Offline
            MMRIZE @shall_
            last edited by Apr 11, 2024, 4:55 AM

            @shall_
            Are you using MMM-GoogleCalendar?

            S 1 Reply Last reply Apr 12, 2024, 9:58 PM Reply Quote 0
            • S Offline
              shall_ @MMRIZE
              last edited by Apr 12, 2024, 9:58 PM

              @MMRIZE i am using the MMM-GoogleCalendar module

              1 Reply Last reply Reply Quote 0
              • S Offline
                shall_ @shall_
                last edited by May 18, 2024, 7:40 PM

                I have managed to fix my issue, it seems the event transformer I was using (to colour mt events) may have been contradicting the fix.

                I removed the following from my event transformer which fixed the issue!

                  e.startDate = new Date(e.start?.date || e.start?.dateTime).valueOf()
                  e.endDate = new Date(e.end?.date || e.end?.dateTime).valueOf()
                
                1 Reply Last reply Reply Quote 0
                • S sdetweil has marked this topic as solved on May 18, 2024, 10:25 PM
                • 1
                • 2
                • 3
                • 3 / 3
                • First post
                  Last post
                Enjoying MagicMirror? Please consider a donation!
                MagicMirror created by Michael Teeuw.
                Forum managed by Sam, technical setup by Karsten.
                This forum is using NodeBB as its core | Contributors
                Contact | Privacy Policy